JBoss Tools SVN: r20649 - branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2010-03-04 07:44:54 -0500 (Thu, 04 Mar 2010)
New Revision: 20649
Modified:
branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java
Log:
JBIDE-5992: Inserting tag into selected element causes NullPointerException
issue is fixed
Modified: branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java
===================================================================
--- branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java 2010-03-04 12:44:41 UTC (rev 20648)
+++ branches/jbosstools-3.1.x/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java 2010-03-04 12:44:54 UTC (rev 20649)
@@ -503,6 +503,8 @@
private void fillElReferencesForNode(IDOMNode node, XmlContextImpl context) {
if(Node.ELEMENT_NODE == node.getNodeType() || Node.TEXT_NODE == node.getNodeType()) {
IStructuredDocumentRegion regionNode = node.getFirstStructuredDocumentRegion();
+ if (regionNode == null)
+ return;
ITextRegionList regions = regionNode.getRegions();
for(int i=0; i<regions.size(); i++) {
ITextRegion region = regions.get(i);
14 years, 10 months
JBoss Tools SVN: r20648 - in branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial: en and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 07:44:41 -0500 (Thu, 04 Mar 2010)
New Revision: 20648
Modified:
branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master.xml
branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master_output.xml
branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/pom.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Modified: branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master.xml
===================================================================
--- branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master.xml 2010-03-04 12:40:59 UTC (rev 20647)
+++ branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master.xml 2010-03-04 12:44:41 UTC (rev 20648)
@@ -43,14 +43,14 @@
<author><firstname>Svetlana</firstname><surname>Mukhina</surname><email>smukhina(a)exadel.com</email></author>
<copyright>
- <year>2007</year>
+ <year>2007</year>
<year>2008</year>
- <year>2009</year>
+ <year>2009</year>
<year>2010</year>
<holder>JBoss by Red Hat</holder>
</copyright>
<releaseinfo>
- Version: 3.1.0.CR1
+ Version: 3.1.0.GA
</releaseinfo>
<abstract>
Modified: branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master_output.xml
===================================================================
--- branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master_output.xml 2010-03-04 12:40:59 UTC (rev 20647)
+++ branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/en/master_output.xml 2010-03-04 12:44:41 UTC (rev 20648)
@@ -22,1371 +22,1373 @@
<!ENTITY strutsreflink "../../struts_tools_ref_guide/html_single/index.html">
<!ENTITY strutstutoriallink "../../struts_tools_tutorial/html_single/index.html">
-]><book xmlns:diffmk="http://diffmk.sf.net/ns/diff">
-
- <bookinfo>
- <title>Struts Tools Tutorial</title>
- <corpauthor>
- <inlinemediaobject>
- <imageobject role="fo">
- <imagedata fileref="images/jbosstools_logo.png" format="PNG"></imagedata>
- </imageobject>
- <imageobject role="html">
- <imagedata></imagedata>
- </imageobject>
- </inlinemediaobject>
- </corpauthor>
- <author><firstname>Anatoly</firstname><surname>Fedosik</surname></author>
- <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
- <author><firstname>Svetlana</firstname><surname>Mukhina</surname><email>smukhina(a)exadel.com</email></author>
-
- <pubdate>April 2008</pubdate>
- <copyright>
- <year>2007</year>
- <year>2009</year>
- <holder>JBoss by Red Hat</holder>
- </copyright>
- <releaseinfo><diffmk:wrapper diffmk:change="changed">
- Version: 3.1.0.CR1
- </diffmk:wrapper></releaseinfo>
-
-<abstract>
- <title></title>
- <para>
- <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/struts_tools_tutoria...">PDF version</ulink>
- </para>
-</abstract>
-
-
- </bookinfo>
-
- <toc></toc>
-
-
-<chapter id="introduction" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/introduction.xml" xreflabel="introduction">
- <?dbhtml filename="introduction.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Eclipse</keyword>
- <keyword>Java</keyword>
- <keyword>JBoss</keyword>
- </keywordset>
- </chapterinfo>
- <title>Introduction</title>
- <para>The following chapters describe how to deal with classic/old style of Struts development. We
- recommend users to use <ulink url="../../seam/html_single/index.html">JBoss Seam</ulink> to
- simplify development, but until then you can read about classical Struts usage here.</para>
-
- <para>We are going to show you how to create a simple <emphasis>
- <property moreinfo="none">Struts application</property>
- </emphasis> using the JBoss Tools. The completed application will ask a user to enter
- a name and click a button. The resulting new page will display the familiar message,
- "Hello <name>!"</para>
- <para>This document will show you how to create such an application from the beginning, along the
- way demonstrating some of the powerful features of JBoss Tools. With the help of our tutorial you will design the
- application, generate stub code for the application, fill in the stub coding, compile the
- application, and finally run it all from inside the Eclipse.</para>
-
- <section>
- <title>Key Features Struts Tools</title>
-
- <para>For a start, we propose you to look through the table of main features of Struts
- Tools:</para>
- <table>
-
- <title>Key Functionality of Struts Tools</title>
- <tgroup cols="2">
-
- <colspec align="left" colnum="1" colwidth="2*"></colspec>
- <colspec colnum="2" colwidth="4*"></colspec>
-
-
- <thead>
- <row>
- <entry>Feature</entry>
- <entry>Benefit</entry>
-
- </row>
- </thead>
- <tbody>
- <row>
- <entry><para>Struts Support</para></entry>
- <entry><para>Step-by-step wizards for creating a new struts project with a number
- of predefined templates, importing existing ones and adding struts
- capabilities to non-struts web projects.</para></entry>
-
- </row>
-
- <row>
- <entry><para>Support for Struts Configuration File</para></entry>
- <entry><para>Working on file using three modes: diagram, tree and source.
- Synchronization between the modes and full control over the code. Easy
- moving around the diagram using the Diagram Navigator. Working with
- struts projects that have multiple modules. Possibility to use Struts
- configuration file debugger allowing to set break points on struts
- diagram and then launch the server in debug mode.</para></entry>
-
- </row>
-
- <row>
- <entry><para>Support for Struts modules</para></entry>
- <entry><para>A Struts module (struts-config.xml) is automatically created while
- creating a new project. There is also possibility to add new ones or edit
- already existing modules in your existing project or while importing Struts project.</para></entry>
-
- </row>
-
- <row>
- <entry><para>Verification and Validation</para></entry>
- <entry><para>All occurring errors will be immediately reported by verification
- feature, no matter in what view you are working. Constant validation and
- errors checking allows to catch many of the errors during development
- process that significantly reduces development time.</para></entry>
-
-
- </row>
- </tbody>
- </tgroup>
- </table>
- </section>
-
-
-
- <section>
- <title>Other relevant resources on the topic</title>
-
- <para>All JBoss Developer Studio/JBoss Tools release documentation you can find at<ulink url="http://docs.jboss.org/tools/">http://docs.jboss.org/tools</ulink> in the corresponding release directory.</para>
- <para>The latest documentation builds are available at <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">http://download.jboss.org/jbosstools/nightly-docs</ulink>.</para>
-
- </section>
-
-</chapter>
-
-
-<chapter id="struts_application" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/struts_application.xml" xreflabel="struts_application">
- <?dbhtml filename="struts_application.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Application</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Creating a Simple Struts Application</title>
-
- <para>Firstly, we assume that you have already launched Eclipse with <property moreinfo="none">JBoss Tools</property> installed and
- also that the <property moreinfo="none">Web Development perspective</property> is the current perspective. (If not, make it
- active by selecting <emphasis>
- <property moreinfo="none">Window > Open Perspective > Other > Web
- Development</property>
- </emphasis> from the menu bar.)</para>
-
- <section id="StartingUp">
- <title>Starting Up</title>
- <para>We are first going to create a new project for the application.</para>
- <itemizedlist>
- <listitem>
- <para>Go to the menu bar and select <emphasis>
- <property moreinfo="none">File > New > Struts Project</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Next enter "StrutsHello" as the project name</para>
- </listitem>
- <listitem>
- <para>Leave everything else as it is, and click <emphasis>
- <property moreinfo="none">Next</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>If you have server runtime already defined, just pass to next point. Otherwise in the <emphasis>
- <property moreinfo="none">Runtime</property></emphasis> section click the <emphasis>
- <property moreinfo="none">New</property></emphasis> button and target at needed server runtime environment. Click <emphasis>
- <property moreinfo="none">Finish</property>.</emphasis></para>
- </listitem>
- <listitem>
- <para>Click <emphasis>
- <property moreinfo="none">Next</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Make sure that <emphasis>
- <property moreinfo="none">struts-bean.tld</property>
- </emphasis>, <emphasis>
- <property moreinfo="none">struts-html.tld</property>
- </emphasis>, and <emphasis>
- <property moreinfo="none">struts-logic.tld</property>
- </emphasis> are checked in the list of included tag libraries and then hit <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
- </itemizedlist>
- <para>A "StrutsHello" node should appear in the <property moreinfo="none">Package
- Explorer view</property>.</para>
- <itemizedlist>
- <listitem>
- <para>Click the plus sign next to <emphasis>
- <property moreinfo="none">StrutsHello</property>
- </emphasis> to reveal the child nodes</para>
- </listitem>
- <listitem>
- <para>Click the plus sign next to <emphasis>
- <property moreinfo="none">WebContent</property>
- </emphasis> under <emphasis>
- <property moreinfo="none">StrutsHello</property></emphasis></para>
- </listitem>
- <listitem>
- <para>Click the plus sign next to <emphasis>
- <property moreinfo="none">WEB-INF</property>
- </emphasis> under <emphasis>
- <property moreinfo="none">WebContent</property></emphasis></para>
- </listitem>
- <listitem>
- <para>Then, double-click on the <emphasis>
- <property moreinfo="none">struts-config.xml</property>
- </emphasis> node to display a diagram of the Struts application configuration
- file in the editing area</para>
- </listitem>
- </itemizedlist>
- <para>At this point, its empty except for the background grid lines.</para>
- </section>
-
- <section id="CreatingtheApplicationComponents">
- <?dbhtml filename="CreatingtheApplicationComponents.html"?>
- <title>Creating the Application Components</title>
- <para>Now, we will design the application by creating the individual components as
- placeholders first. (We don't have to complete all of the details inside the components
- until afterwards.)</para>
- <section id="CreatingJSPPagePlaceholders">
- <title>Creating JSP Page Placeholders</title>
- <para>Next, let's create and place two JSP pages. We will not write any code
- for the files, but only create them as placeholders so that we can create links to
- them in the diagram. We will write the code a little bit later.</para>
- <section id="CreatingthePagePlaceholders">
- <title>Creating the Page Placeholders</title>
- <itemizedlist>
- <listitem>
- <para>Bring the <property moreinfo="none">Web Projects view</property> to the front of the <property moreinfo="none">Package Explorer view</property>
- by selecting the <emphasis>
- <property moreinfo="none">Web Projects</property>
- </emphasis> tab next to that tab.</para>
- </listitem>
- <listitem>
- <para>Right-click the <emphasis>
- <property moreinfo="none">StrutsHello > WEB-ROOT (WebContent)</property>
- </emphasis> folder in the <property moreinfo="none">Web Projects view</property> and select <emphasis>
- <property moreinfo="none">New > Folder...</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Enter <emphasis>
- <property moreinfo="none">pages</property>
- </emphasis> for a folder name and click <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
-
- <listitem>
- <para>We will keep our presentation files in this folder</para>
- </listitem>
-
- <listitem>
- <para>Right-click the <emphasis>
- <property moreinfo="none">pages</property></emphasis> folder and select <emphasis>
- <property moreinfo="none">New > File > JSP...</property>
- </emphasis>
- </para>
- </listitem>
- <listitem>
- <para>For Name type in <emphasis>
- <property moreinfo="none">inputname</property>
- </emphasis> (the JSP extension will be automatically added to the file),
- for Template select <emphasis>
- <property moreinfo="none">StrutsForm</property>
- </emphasis> and then click on the <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis> button</para>
- </listitem>
- <listitem>
- <para>Right-click the <emphasis>
- <property moreinfo="none">pages</property></emphasis> folder again and select <emphasis>
- <property moreinfo="none">New > File > JSP...</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>For Name type in <emphasis>
- <property moreinfo="none">greeting</property>
- </emphasis>, for Template leave as <emphasis>
- <property moreinfo="none">Blank</property>,</emphasis> and then click on the <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis> button</para>
- </listitem>
- </itemizedlist>
- <para>Just leave these files as is for now.</para>
- </section>
- <section id="PlacingthePagePlaceholders">
- <title>Placing the Page Placeholders</title>
- <para>Lets now place the two pages just created on the diagram.</para>
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">struts-config.xml</property>
- </emphasis> tab in the editing area to bring the diagram to the
- front</para>
- </listitem>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">inputname.jsp</property>
- </emphasis> page in the <property moreinfo="none">Web Projects view</property>, drag it onto the diagram, and
- drop it</para>
- </listitem>
- <listitem><para>Click on the <emphasis>
- <property moreinfo="none">greeting.jsp</property>
- </emphasis> page in the <property moreinfo="none">Web Projects view</property>, drag it onto the diagram, and
- drop it to the right of the <emphasis>
- <property moreinfo="none">/pages/inputname.jsp</property>
- </emphasis> icon with some extra space</para></listitem>
- </itemizedlist>
- <para>You should now have two JSP pages in the diagram.</para>
- </section>
- </section>
- <section id="CreatinganActionMappings">
- <title>Creating an Action Mappings</title>
- <para>Using a context menu on the diagram, we are next going to create an Action
- mapping.</para>
- <itemizedlist>
- <listitem>
- <para>Right-click between the two icons and select <emphasis>
- <property moreinfo="none">New > Action</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Enter the following values:</para>
- </listitem>
- </itemizedlist>
- <table>
- <title>Action values</title>
- <tgroup cols="2">
- <tbody>
- <row>
- <entry>path</entry>
- <entry>/greeting</entry>
- </row>
- <row>
- <entry>name</entry>
- <entry>GetNameForm</entry>
- </row>
- <row>
- <entry>scope</entry>
- <entry>request</entry>
- </row>
- <row>
- <entry>type</entry>
- <entry>sample.GreetingAction</entry>
- </row>
- <row>
- <entry>validate</entry>
- <entry><leave blank></entry>
- </row>
- </tbody>
- </tgroup>
- </table>
- <para>("GetNameForm" is the name for a form bean that we will create
- later.)</para>
- <itemizedlist>
- <listitem>
- <para>Click <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
- </itemizedlist>
-
- <para>The <emphasis>
- <property moreinfo="none">/greeting</property>
- </emphasis> action should appear in four places, in the diagram, under the
- <emphasis>
- <property moreinfo="none">action-mappings</property></emphasis> node, under the <emphasis>
- <property moreinfo="none">struts-config.xml</property></emphasis> node in Tree view, in <property moreinfo="none">Web Projects
- view</property> and in the <property moreinfo="none">Outline view</property>. Also, note the asterisk to the right of the name,
- <emphasis>
- <property moreinfo="none">struts-config.xml</property>,</emphasis> in the <property moreinfo="none">Outline view</property> showing that the file has been changed, but
- not saved to disk.</para>
- </section>
- <section id="CreatingaLink">
- <title>Creating a Link</title>
- <para>Let's now create a link from the <emphasis>
- <property moreinfo="none">inputname.jsp</property></emphasis> page to the action.</para>
- <itemizedlist>
- <listitem>
- <para>On the left-hand side of the diagram in the column of icons, click on the Create New Connection
- icon( <inlinemediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_1.png"></imagedata>
- </imageobject>
- </inlinemediaobject>).</para>
- </listitem>
- </itemizedlist>
- <itemizedlist>
- <listitem>
- <para>In the connect-the-components mode you are in now, click on the <emphasis>
- <property moreinfo="none">/pages/inputname.jsp</property>
- </emphasis> icon in the diagram and then click on the <emphasis>
- <property moreinfo="none">/greeting</property>
- </emphasis> action</para>
- </listitem>
- </itemizedlist>
- <para>A link will be created from the page to the action.</para>
- </section>
- <section id="CreatingaForward">
- <title>Creating a Forward</title>
- <para>Next, we are going to create a forward for the action.</para>
- <itemizedlist>
- <listitem>
- <para>On the left-hand side of the diagram in the column of icons, click on
- the Create New Connection
- icon( <inlinemediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_1.png"></imagedata>
- </imageobject>
- </inlinemediaobject>), again.</para>
- </listitem>
- </itemizedlist>
-
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">/greeting</property>
- </emphasis> action icon in the diagram and then click on the <emphasis>
- <property moreinfo="none">pages/greeting.jsp</property>
- </emphasis> icon</para>
- </listitem>
- <listitem>
- <para>That's it. A link will be drawn from the actions new greeting
- forward to the <emphasis>
- <property moreinfo="none">greeting.jsp</property></emphasis> JSP page. Note that the forwards name will be
- set based on the name of the target JSP file name. If you don't
- like it, you can easily change it</para>
- </listitem>
- <listitem>
- <para>Select the <emphasis>
- <property moreinfo="none">Tree</property>
- </emphasis> tab at the bottom of the editor window (between Diagram and
- Source)</para>
- </listitem>
- <listitem>
- <para>Expand the <emphasis>
- <property moreinfo="none">struts-config.xml/action-mappings/ /greeting</property>
- </emphasis> node and then select the greeting forward</para>
- </listitem>
- <listitem>
- <para>In the Properties Editor to the right, change the text to
- "sayHello" in the <emphasis>
- <property moreinfo="none">Name</property></emphasis> field</para>
- </listitem>
- <listitem>
- <para>Select the <emphasis>
- <property moreinfo="none">Diagram</property>
- </emphasis> tab at the bottom of the editor window and see how the diagram
- is also updated to reflect the change</para>
- </listitem>
- </itemizedlist>
- </section>
- <section id="CreatingaGlobalForward">
- <title>Creating a Global Forward</title>
- <para>One last component that we need to create in the diagram is a global forward.</para>
- <itemizedlist>
- <listitem>
- <para>Somewhere in the top-left corner of diagram, right-click and select <emphasis>
- <property moreinfo="none">New > Global Forward</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Enter <emphasis>
- <property moreinfo="none">getName</property>
- </emphasis> in the <emphasis>
- <property moreinfo="none">Name</property></emphasis> field</para>
- </listitem>
- <listitem>
- <para>Select the <emphasis>
- <property moreinfo="none">Change...</property>
- </emphasis>button for Path</para>
- </listitem>
- <listitem>
- <para>In the Edit Path window, switch to the <emphasis>
- <property moreinfo="none">Pages</property>
- </emphasis> tab</para>
- </listitem>
- <listitem>
- <para>Expand the <emphasis>
- <property moreinfo="none">StrutsHello > WEB-ROOT (WebContent) > pages</property>
- </emphasis> node and then select the inputname.jsp page</para>
- </listitem>
- <listitem>
- <para>Click <emphasis>
- <property moreinfo="none">Ok</property>
- </emphasis>.</para>
- </listitem>
- <listitem>
- <para>Leave the rest of the fields blank and click <emphasis>
- <property moreinfo="none">OK</property>
- </emphasis></para>
- </listitem>
- </itemizedlist>
- <para>A forward object now appears on the diagram and also in the global-forwards folder
- in the Outline view.</para>
- <itemizedlist>
- <listitem>
- <para>Tidy up the diagram, by clicking and dragging around each icon, so that
- the diagram looks something like this:</para>
- </listitem>
- </itemizedlist>
- <figure float="0">
- <title>Diagram View</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_2.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
- </section>
- <section id="CreatingaFormBean">
- <title>Creating a Form Bean</title>
- <para>One last thing that we need to do is to create a form bean.</para>
- <itemizedlist>
- <listitem>
- <para>Switch to the Tree viewer in the editor for the <emphasis>
- <property moreinfo="none">struts-config.xml</property></emphasis> file, by
- selecting the <emphasis>
- <property moreinfo="none">Tree</property>
- </emphasis> tab at the bottom of the editor window</para>
- </listitem>
- <listitem>
- <para>Right-click <emphasis>
- <property moreinfo="none">struts-config.xml > form-beans</property>
- </emphasis> and select Create Form Bean</para>
- </listitem>
- <listitem>
- <para>Enter <emphasis>
- <property moreinfo="none">GetNameForm</property>
- </emphasis> in the name field and <emphasis>
- <property moreinfo="none">sample.GetNameForm</property>
- </emphasis> for type</para>
- </listitem>
- <listitem>
- <para>Click <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>To save your changes to struts-config.xml, select <emphasis>
- <property moreinfo="none">File > Save</property>
- </emphasis> from the menu bar</para>
- </listitem>
- </itemizedlist>
- <para>Note the disappearance of the asterisk next to the name, <emphasis>
- <property moreinfo="none">struts-config.xml</property>.</emphasis></para>
- </section>
- </section>
-</chapter>
-
-<chapter id="generating_stub" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/generating_stub.xml" xreflabel="generating_stub">
- <?dbhtml filename="generating_stub.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Application</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Generating Stub Coding</title>
- <para>We are done with designing the application through the diagram. Now we need to write
- code for the action component. We also need to write an action class for the <emphasis>
- <property moreinfo="none">/greeting</property>
- </emphasis> mapping along with a FormBean. To aid in the coding phase, JBoss Developer
- Studio can generate Java class stubs for all of the components shown in the diagram.</para>
- <itemizedlist>
- <listitem>
- <para>Switch back to the diagram, by selecting the <emphasis>
- <property moreinfo="none">Diagram</property>
- </emphasis> tab at the bottom of the editor window</para>
- </listitem>
- <listitem>
- <para>Right-click a blank space in the diagram and select <emphasis>
- <property moreinfo="none">Generate Java Code</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Leave everything as is in the dialog box and click <emphasis>
- <property moreinfo="none">Generate</property>
- </emphasis></para>
- </listitem>
- </itemizedlist>
- <para>You should see a screen that says:</para>
- <para>Generated classes: 2</para>
- <para>Actions: 1</para>
- <para>Form beans: 1</para>
- <itemizedlist>
- <listitem>
- <para>Click <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
- </itemizedlist>
- <para>The Java files will be generated in a <emphasis>
- <property moreinfo="none">JavaSource > sample</property>
- </emphasis> folder that you can see in the <property moreinfo="none">Package Explorer view</property> under the
- "StrutsHello" node. One Action stub and one FormBean stub will have
- been generated.</para>
- </chapter>
-
-<chapter id="coding_files" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/coding_files.xml" xreflabel="coding_files">
- <?dbhtml filename="coding_files.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Application</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Coding the Various Files</title>
- <para>We will now code both the Java stub classes just generated, the JSP files left in as
- placeholders from previous steps, and a new start JSP page we will have to create.</para>
- <section id="JavaStubClasses">
- <title>Java Stub Classes</title>
- <itemizedlist>
- <listitem>
- <para>To finish the two Java classes, switch to the <emphasis>
- <property moreinfo="none">Package Explorer</property>
- </emphasis> view and expand the <emphasis>
- <property moreinfo="none">JavaSource > sample</property>
- </emphasis> folder</para>
- </listitem>
- </itemizedlist>
- <section id="GetNameForm.java">
- <title>GetNameForm.java</title>
- <itemizedlist>
- <listitem>
- <para>Double-click <emphasis>
- <property moreinfo="none">GetNameForm.java</property>
- </emphasis> for editing</para>
- </listitem>
-
- <listitem>
- <para>You are looking at a Java stub class that was generated by JBoss
- Tools. Now we are going to edit the file</para>
- </listitem>
-
- <listitem>
- <para>Add the following attributes at the beginning of the class:</para>
- </listitem>
- </itemizedlist>
- <programlisting format="linespecific" role="JAVA"><![CDATA[private String name = "";
-]]></programlisting>
-
- <itemizedlist>
- <listitem>
- <para>Inside the reset method, delete the TO DO and throw lines and
- add:</para>
- </listitem>
- </itemizedlist>
- <programlisting format="linespecific" role="JAVA"><![CDATA[this.name = "";
-]]></programlisting>
-
- <itemizedlist>
- <listitem>
- <para>Inside the validate method, delete the TO DO and throw lines and
- add:</para>
- </listitem>
- </itemizedlist>
- <programlisting format="linespecific" role="JAVA"><![CDATA[ActionErrors errors = new ActionErrors();
- return errors;
-]]></programlisting>
-
- <itemizedlist>
- <listitem>
- <para>Right-click and select <emphasis>
- <property moreinfo="none">Source > Generate Getters and Setters</property>
- </emphasis>from the context menu</para>
- </listitem>
- <listitem>
- <para>In the dialog box, check the check box for <emphasis>
- <property moreinfo="none">name</property>,</emphasis>
- select First method for Insertion point, and click on the <emphasis>
- <property moreinfo="none">OK</property>
- </emphasis> button</para>
- </listitem>
- </itemizedlist>
- <para>The final <emphasis>
- <property moreinfo="none">GetNameForm.java</property></emphasis> file should look like this:</para>
- <programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
-import javax.servlet.http.HttpServletRequest;
-import org.apache.struts.action.ActionErrors;
-import org.apache.struts.action.ActionMapping;
-
-public class GetNameForm extends org.apache.struts.action.ActionForm
-{
-
- private String name = "";
-
- public String getName()
- {
- return name;
- }
- public void setName(String name)
- {
- this.name = name;
- }
-
- public GetNameForm()
- {
- }
-
- public void reset(ActionMapping actionMapping, HttpServletRequest request)
- {
- this.name = "";
- }
-
- public ActionErrors validate(ActionMapping actionMapping,
- HttpServletRequest request)
- {
- ActionErrors errors = new ActionErrors();
- return errors;
- }
-}
-]]></programlisting>
-
- <itemizedlist>
- <listitem>
- <para>Save the file</para>
- </listitem>
- </itemizedlist>
- </section>
- <section id="GreetingAction.java">
- <title>GreetingAction.java</title>
- <itemizedlist>
- <listitem>
- <para>Open <emphasis>
- <property moreinfo="none">GreetingAction.java</property></emphasis> for editing</para>
- </listitem>
- <listitem>
- <para>Inside the execute method, delete the TO DO lines and add the
- following:</para>
- </listitem>
- </itemizedlist>
-
- <programlisting format="linespecific" role="JAVA"><![CDATA[String name = ((GetNameForm)form).getName();
-String greeting = "Hello, "+name+"!";
-((GetNameForm)form).setName(greeting);
-return mapping.findForward(FORWARD_sayHello);
-]]></programlisting>
-
- <para>The final version of <emphasis>
- <property moreinfo="none">GreetingAction.java</property></emphasis> should look like this:</para>
-
- <programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import org.apache.struts.action.ActionForm;
-import org.apache.struts.action.ActionForward;
-import org.apache.struts.action.ActionMapping;
-
-public class GreetingAction extends org.apache.struts.action.Action
-{
-
- // Global Forwards
- public static final String GLOBAL_FORWARD_getName = "getName";
-
- // Local Forwards
- public static final String FORWARD_sayHello = "sayHello";
-
- public GreetingAction()
- {
- }
- public ActionForward execute(ActionMapping mapping, ActionForm form,
- HttpServletRequest request, HttpServletResponse response) throws Exception
- {
- String name = ((GetNameForm)form).getName();
- String greeting = "Hello, "+name+"!";
- ((GetNameForm)form).setName(greeting);
- return mapping.findForward(FORWARD_sayHello);
- }
-}
-]]></programlisting>
- <itemizedlist>
- <listitem>
- <para>Save the file</para>
- </listitem>
- <listitem>
- <para>Close the editors for the two Java files</para>
- </listitem>
- </itemizedlist>
- <para>The last thing left to do is to code the JSP files whose editors should still
- be open from having been created as placeholders.</para>
- </section>
- </section>
- <section id="JSPPages">
- <title>JSP Pages</title>
- <section id="inputname.jsp">
- <title>inputname.jsp</title>
- <para>In this page, the user will enter any name and click the <emphasis>
- <property moreinfo="none">submit</property>
- </emphasis> button. Then, the greeting action will be called through the form.</para>
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">inputname.jsp</property>
- </emphasis> tab in the Editing area to bring its editor forward</para>
- </listitem>
- <listitem>
- <para>In the Web Projects view, expand <emphasis>
- <property moreinfo="none">StrutsHello > Configuration > default
- > struts-config.xml > action-mappings</property>
- </emphasis> and select <emphasis>
- <property moreinfo="none">/greeting</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Drag it and drop it between the quotes for the <emphasis role="italic">
- <property moreinfo="none">"action"</property>
- </emphasis> attribute to the
- <code><html:form></code>
- element in the Source pane of the editor</para>
- </listitem>
- <listitem>
- <para>Then type this text on a new line just below this line:</para>
- <programlisting format="linespecific" role="XML"><![CDATA[Input name:
- ]]></programlisting>
- </listitem>
-
- <listitem>
- <para>Select the <emphasis>
- <property moreinfo="none">Visual</property>
- </emphasis> pane of the editor</para>
- </listitem>
- <listitem>
- <para>Then, in the JBoss Tools Palette, expand the <emphasis>
- <property moreinfo="none">Struts Form</property>
- </emphasis> library, select <emphasis>
- <property moreinfo="none">text</property>
- </emphasis>, and drag it onto the box
- <note>
- <title>Note:</title>
- <para>By default there are only four groups on the JBoss Tools
- Palette. If you wish to make some group visible click the <emphasis>
- <property moreinfo="none">Show/Hide</property>
- </emphasis> button on the top of palette and in the prompted
- dialog check the group (or groups) you want to be shown.</para>
- </note>
- </para>
- </listitem>
- </itemizedlist>
- <figure float="0">
- <title>JBoss Tools Palette</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_3.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
- <itemizedlist>
- <listitem>
- <para>In the Insert Tag dialog box, type in name for property and select <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>In the StrutsForm library in the <property moreinfo="none">JBoss Tools Palette</property>, select <emphasis>
- <property moreinfo="none">submit</property>
- </emphasis>, and drag it to right after the text box in the Visual pane
- of the editor</para>
- </listitem>
- <listitem>
- <para>Right-click the <emphasis>
- <property moreinfo="none">submit</property>
- </emphasis> button and select
- <code><html:submit></code>
- Attributes from the context menu</para>
- </listitem>
- <listitem>
- <para>In the Attributes dialog box, select the <emphasis>
- <property moreinfo="none">value</property>
- </emphasis> field and type in "Say Hello!" for its
- value</para>
- </listitem>
- </itemizedlist>
- <para>After tidying the page source, the Editor window for the file should look
- something like this:</para>
- <figure float="0">
- <title>Editor Window</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_4.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
- </section>
- <section id="greeting.jsp">
- <title>greeting.jsp</title>
- <para>Next, we will fill in the result page.</para>
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">greeting.jsp</property>
- </emphasis> tab in the Editing area to bring its editor forward</para>
- </listitem>
- <listitem>
- <para>Type in the following code:</para>
- </listitem>
- </itemizedlist>
- <programlisting format="linespecific" role="XML"><![CDATA[<html>
-<head>
- <title>Greeting</title>
-</head>
- <body>
- <p>
- </p>
- </body>
-</html>
-]]></programlisting>
-
- <para>To complete editing of this file, we will use macros from the <property moreinfo="none">JBoss Tools
- Palette</property>. This palette is a view that should be available to the right of the
- editing area.</para>
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">Struts Common</property>
- </emphasis> folder in the <property moreinfo="none">JBoss Tools Palette</property> to open it</para>
- </listitem>
- <listitem>
- <para>Position the cursor at the beginning of the <emphasis>
- <property moreinfo="none">greeting.jsp</property></emphasis> file in the
- Source pane and then click on <emphasis>
- <property moreinfo="none">bean taglib</property></emphasis> in the <property moreinfo="none">JBoss Tools
- Palette</property></para>
- </listitem>
- </itemizedlist>
- <para>This will insert the following line at the top of the file:</para>
- <programlisting format="linespecific" role="JAVA"><![CDATA[
-<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
-]]></programlisting>
- <itemizedlist>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">Struts Bean</property>
- </emphasis> folder in the <property moreinfo="none">JBoss Tools Palette</property> to open it</para>
- </listitem>
- <listitem>
- <para>Position the cursor inside the
- <code><p></code>
- element</para>
- </listitem>
- <listitem>
- <para>Click on <emphasis>
- <property moreinfo="none">write</property></emphasis> in the <property moreinfo="none">JBoss Tools Palette</property></para>
- </listitem>
- <listitem>
- <para>Type in "GetNameForm" for the <emphasis role="italic">
- <property moreinfo="none">name</property>
- </emphasis> attribute and add a <emphasis role="italic">
- <property moreinfo="none">property</property>
- </emphasis> attribute with "name" as its
- value</para>
- </listitem>
- </itemizedlist>
- <para>The editor should now look like this:</para>
- <figure float="0">
- <title>Editor Window</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_5.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
- </section>
- <section id="index.jsp">
- <title>index.jsp</title>
- <para>Finally, we will need to create and edit an <emphasis>
- <property moreinfo="none">index.jsp</property></emphasis> page. This page will use
- a Struts forward to simply redirect us to the getName global forward.</para>
- <itemizedlist>
- <listitem>
- <para>In the Web Projects view, right-click on <emphasis>
- <property moreinfo="none">StrutsHello > WEB-ROOT(WebContent)</property>
- </emphasis> node and select <emphasis>
- <property moreinfo="none">New > File > JSP</property>
- </emphasis></para>
- </listitem>
- <listitem>
- <para>Type <emphasis>
- <property moreinfo="none">index</property></emphasis> for Name and click on the <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis> button</para>
- </listitem>
- <listitem>
- <para>On the <property moreinfo="none">JBoss Tools Palette</property>, select the <emphasis>
- <property moreinfo="none">Struts Common</property>
- </emphasis> folder of macros by clicking on it in the palette</para>
- </listitem>
- <listitem>
- <para>Click on the <emphasis>
- <property moreinfo="none">logic taglib</property></emphasis> icon</para>
- </listitem>
- <listitem>
- <para>Press the <emphasis>
- <property moreinfo="none">Enter</property>
- </emphasis> key in the editor to go to the next line</para>
- </listitem>
- <listitem>
- <para>Back on the palette, select the <emphasis>
- <property moreinfo="none">Struts Logic</property>
- </emphasis> folder of macros</para>
- </listitem>
- <listitem>
- <para>Click on <emphasis>
- <property moreinfo="none">redirect</property></emphasis></para>
- </listitem>
- <listitem>
- <para>Delete the ending tag, put a forward slash in front of the closing
- angle bracket, and type "forward=getName" in front of
- the slash</para>
- </listitem>
- </itemizedlist>
- <para>The finished code for the page is shown below:</para>
- <programlisting format="linespecific" role="JAVA"><![CDATA[<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
-<logic:redirect forward="getName"/>
-]]></programlisting>
- <itemizedlist>
- <listitem>
- <para>To save all the edits to files, select <emphasis>
- <property moreinfo="none">File>Save All</property>
- </emphasis> from the menu bar</para>
- </listitem>
- </itemizedlist>
- </section>
- </section>
- </chapter>
-
-<chapter id="compiling_and_running" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/compiling_and_running.xml" xreflabel="compiling_and_running">
- <?dbhtml filename="compiling_and_running.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Application</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Compiling the Classes and Running the Application</title>
-
- <para>As this is the Eclipse environment, no explicit compilation step is required. By
- default, Eclipse compiles as you go.</para>
-
- <para>Thus at this point everything is ready for running our application without having to leave JBoss
- Developer Studio by using the JBoss Application Server engine that comes with the JBoss
- Developer Studio. For controlling JBoss AS within JBoss Developer Studio, there is JBoss
- Server view.</para>
- <figure float="0">
- <title>JBoss Server Panel</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_application/struts_application_6.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
- <itemizedlist>
- <listitem>
- <para>Start up JBoss AS by clicking on the icon in JBoss Server view. (If JBoss AS
- is already running, stop it by clicking on the red icon and then start it again.
- Remember, the Struts run-time requires restarting the servlet engine when any
- changes have been made.)</para>
- </listitem>
- <listitem>
- <para>After the messages in the Console tabbed view stop scrolling, JBoss AS is
- available. At this point, right-click on the getName global forward in the
- struts-config.xml diagram view and select Run on Server.</para>
- </listitem>
- </itemizedlist>
- <para>The browser should appear with the application started.</para>
- </chapter>
-
-<chapter id="struts_validation" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/struts_validation.xml" xreflabel="struts_validation">
- <?dbhtml filename="struts_validation.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Developer Studio</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Validation</keyword>
- </keywordset>
- </chapterinfo>
-<title>Struts Validation Examples</title>
-
-<para><property moreinfo="none">Validation</property> of input is an important part of any Web application. All Apache Jakarta frameworks,
-including Struts, can use a common Jakarta Validation Framework for streamlining this aspect of Web
-application development. The Validation Framework allows you to define validation rules and then apply these rules on the client-side or the server-side.</para>
-
- <para>JBoss Developer Studio makes using the <property moreinfo="none">Validation Framework</property> in Struts even easier with the help of a specialized editor for the XML files that controls validation in a project. In this document, we'll show you how this all works by creating some simple client-side validation and server-side validation examples.</para>
-
-<section id="StartingPoint">
-<?dbhtml filename="StartingPoint.html"?>
-<title>Starting Point</title>
-<para>The example assumes that you have already created our sample "StrutsHello" application from the
-Getting Started Guide for Creating a Struts Application. You should have the JBoss Developer Studio perspective
- open on this StrutsHello project.</para>
-</section>
-
-<section id="DefiningTheValidationRule">
-<?dbhtml filename="DefiningTheValidationRule.html"?>
-<title>Defining the Validation Rule</title>
-<para>In these steps you will set up the validation that can be used for either client-side or
-server side validation. You need to enable validation as a part of the project, define an error message, and tie it into an appropriate part of the application.</para>
-
-<itemizedlist>
-<listitem><para>Right-click on a "plug-ins" node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml</property></emphasis> node in the Web Projects view and select <emphasis><property moreinfo="none">Create Special Plugin > Validators</property></emphasis> from the context menu</para></listitem>
-<listitem><para>Further down in the Web Projects view, right-click on the
-<emphasis><property moreinfo="none">StrutsHello > ResourceBundles</property></emphasis> node and select <emphasis><property moreinfo="none"> New > Properties File...</property></emphasis>from the context menu</para></listitem>
-<listitem><para>In the dialog box, click on the <emphasis><property moreinfo="none">Browse...</property></emphasis>button next to the Folder field, expand the
- JavaSource folder in this next dialog box, select the sample subfolder, and click on the <emphasis><property moreinfo="none">OK</property></emphasis> button</para></listitem>
- <listitem><para>Back in the first dialog box, type in "applResources" for the Name field and click on the <emphasis><property moreinfo="none">Finish</property></emphasis> button</para></listitem>
-<listitem><para>Right-click on a newly created file and select <emphasis><property moreinfo="none">Add > Default Error Messages</property></emphasis>
- from the context menu</para></listitem>
-
-<listitem><para>Drag up the sample.applResources icon until you can drop it on the resources folder under struts-config.xml</para></listitem>
-<listitem><para>Select<emphasis><property moreinfo="none"> File > Save </property></emphasis>All from the menu bar</para></listitem>
-<listitem><para>Select validation.xml under the <emphasis><property moreinfo="none">StrutsHello > Validation</property></emphasis> node and double-click it to open it with the JBoss Tools XML Editor</para></listitem>
-<listitem><para>Here you must create a Formset.</para></listitem>
-<listitem><para>In the validation.xml file editor click the button <emphasis><property moreinfo="none">Create Formset</property></emphasis> on the panel <emphasis><property moreinfo="none">Formsets</property></emphasis></para></listitem>
-<listitem><para>In the dialog <emphasis><property moreinfo="none">Add Formset</property></emphasis> fill the fields <emphasis><property moreinfo="none">Language</property></emphasis> and <emphasis><property moreinfo="none">Country</property></emphasis> or just leave them empty to create a default formset. Click <emphasis><property moreinfo="none">OK</property></emphasis></para></listitem>
-</itemizedlist>
-<figure float="0">
- <title>Create Formset</title>
-<mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_validation/struts_validation.png"></imagedata>
- </imageobject>
-</mediaobject>
-</figure>
-<itemizedlist>
-<listitem><para>Expand the "form-beans" node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml node.</property></emphasis> Then, drag the form bean "GetNameForm" and drop it onto a formset in the <property moreinfo="none">XML</property> Editor</para></listitem>
-<listitem><para>In the Validation Editor, expand the formset node, right-click GetNameForm, and select <emphasis><property moreinfo="none">Create Field...</property></emphasis> from the context menu</para></listitem>
-<listitem><para>Enter a name for Property in the dialog box. A new property will be created:</para></listitem>
-</itemizedlist>
-<figure float="0">
- <title>New Property Is Added</title>
-<mediaobject>
- <imageobject>
- <imagedata fileref="images/struts_validation/struts_validation_2.png"></imagedata>
- </imageobject>
-</mediaobject>
-</figure>
-<itemizedlist>
-<listitem><para>In the Properties view for the name field to the right of the "tree" for the validation.xml file, click on the <emphasis><property moreinfo="none">Change...</property></emphasis>button next to the Depends entry field</para></listitem>
-<listitem><para>In the displayed double list, select <emphasis><property moreinfo="none">required</property></emphasis> from the left list and then click <emphasis><property moreinfo="none">Add</property></emphasis></para></listitem>
- <listitem><para>Click <emphasis><property moreinfo="none">Ok</property></emphasis></para></listitem>
-<listitem><para>Right-click name and select <emphasis><property moreinfo="none">Add Arg...</property></emphasis> from the context menu</para></listitem>
-<listitem><para>In the Add Arg dialog box, click on the <emphasis><property moreinfo="none">Change...</property></emphasis>button next to the <emphasis><property moreinfo="none">Key</property></emphasis> field</para></listitem>
- <listitem><para>In the Key dialog box that appears now, click on the <emphasis><property moreinfo="none">Add</property></emphasis> button</para></listitem>
- <listitem><para>Enter "name.required" in the Name field, and enter a person's name in the Value field</para></listitem>
- <listitem><para>Click <emphasis><property moreinfo="none">Finish</property></emphasis>, then <emphasis><property moreinfo="none">Ok</property></emphasis>, and then <emphasis><property moreinfo="none">Ok</property></emphasis> again</para></listitem>
-<listitem><para>Select <emphasis><property moreinfo="none">File > Save All</property></emphasis> from the menu bar</para></listitem>
-</itemizedlist>
-</section>
-
-<section id="Client-SideValidation">
-<?dbhtml filename="Client-SideValidation.html"?>
-<title>Client-Side Validation</title>
-<para>Client-side <property moreinfo="none">validation</property> uses a scripting language (like JavaScript) running in the client browser to actually do the <property moreinfo="none">validation</property>. In a Struts application using the <property moreinfo="none">Validation</property> Framework, however, you don't actually have to do any of the script coding. The <property moreinfo="none">Validation</property> Framework handles this.</para>
-<para>To see how this works in our application, you'll just need to make a couple of modifications to one of the JSP files.</para>
-<itemizedlist>
-<listitem><para>Double-click inputname.jsp under <emphasis><property moreinfo="none">StrutsHello > WEB-ROOT(WebContent) > pages</property></emphasis> to open it for editing</para></listitem>
-<listitem><para>Find the tag near the top and hit Return to make a new line under it</para></listitem>
- <listitem><para>In the JBoss Tools Palette view to the right, open the Struts HTML folder and click on the javascript tag</para></listitem>
-<listitem><para>Back in the editor, just in front of the closing slash for this inserted tag, hit Ctrl+Space and select "formName" from the prompting menu</para></listitem>
-<listitem><para>Over in the Web Projects view, select GetNameForm under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml > form-beans</property></emphasis> node, drag it, and drop it between the quotes in the editor</para></listitem>
-<listitem><para>Modify the <code><html:form></code> tag by inserting this attribute:</para></listitem>
-</itemizedlist>
-<programlisting format="linespecific" role="XML"><![CDATA[onsubmit="return validateGetNameForm(this)"
-]]></programlisting>
-<para></para>
-<para>The file should now look like this:</para>
-<programlisting format="linespecific" role="XML"><![CDATA[
-<%@ taglib uri="/WEB-INF/struts-html" prefix="html" %>
-
-<html:html >
- <head>
- <html:javascript formName="GetNameForm"/>
- <title></title>
- </head>
- <body>
- <html:form action="/greeting.do" onsubmit="return validateGetNameForm(this)">
- Input name:<html:text property="name"/><html:submit value="Say Hello!"/>
- </html:form>
- </body>
-</html:html>
-]]></programlisting>
-<itemizedlist>
-<listitem><para>Select<emphasis><property moreinfo="none"> File > Save </property></emphasis>from the menu bar</para></listitem>
-<listitem><para>Start JBoss Application Server by clicking on its icon (a right-pointing arrow) in the toolbar</para></listitem>
- <listitem><para>Click the Run icon(<inlinemediaobject> <imageobject>
- <imagedata fileref="images/struts_validation/struts_validation_1.png"></imagedata>
- </imageobject></inlinemediaobject>) or right click your project folder and select <emphasis><property moreinfo="none">Run As > Run on Server</property></emphasis></para></listitem>
-</itemizedlist>
-
-<itemizedlist><listitem><para>In the browser window, click on the "Say Hello!" button without having entered any name in the form</para></listitem></itemizedlist>
-<para>A JavaScript error message should be displayed in an alert box.</para>
-</section>
-<section id="Server-SideValidation">
-<?dbhtml filename="Server-SideValidation.html"?>
-<title>Server Side Validation</title>
-<para>Server side validation does the validation inside the application on the server. In a Struts application using the Validation Framework, you still don't have to do any of the actual validation coding. The Validation Framework handles this. You will though have to make a few changes to the JSP file you modified for client-side validation along with a change to an action and a few changes to the form bean class.</para>
-</section>
-
-<section id="EditingTheJSPFile">
-<?dbhtml filename="EditingTheJSPFile.html"?>
-<title>Editing the JSP File</title>
-<itemizedlist>
-<listitem><para>Reopen inputname.jsp for editing</para></listitem>
-<listitem><para>Delete the <emphasis role="italic"><property moreinfo="none">"onsubmit"</property></emphasis> attribute in the <code><html:form></code> element that you put in for client-side validation</para></listitem>
-
-<listitem><para>Add an <code><html:errors/></code> tag after the
- <code><html:form></code>
- tag</para></listitem>
-</itemizedlist>
-<para>The JSP file should now look like this:</para>
-
- <programlisting format="linespecific" role="XML"><![CDATA[<%@ taglib uri="/WEB-INF/struts-html" prefix="html" %>
-<html:html >
-<head>
- <html:javascript formName="GetNameForm"/>
- <title></title>
- </head>
- <body>
- <html:form action="/greeting.do" >Input name:<html:text property="name"/>
- <html:submit value="Say Hello!"/>
- </html:form>
- <html:errors/>
- </body>
-</html:html>
-]]></programlisting>
-
-</section>
-
-<section id="EditingTheAction">
-<?dbhtml filename="EditingTheAction.html"?>
-<title>Editing the Action</title>
-<itemizedlist>
-<listitem><para>In the Web Projects view, expand the node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml > action-mappings</property></emphasis> node, right-click the <emphasis><property moreinfo="none">/greeting</property></emphasis> action, and then select <emphasis><property moreinfo="none">Properties...</property></emphasis>from the context menu</para></listitem>
-
- <listitem><para>In the Edit Properties window, insert the cursor into the value column for the input property and click on the <property moreinfo="none">...</property> button</para></listitem>
-
- <listitem><para>In the dialog box, make sure the Pages tab is selected, select <emphasis><property moreinfo="none">StrutsHello > WEB-ROOT(WebContent) > pages > inputname.jsp</property></emphasis>, click the <emphasis><property moreinfo="none">Ok</property></emphasis> button, and then click on the <emphasis><property moreinfo="none">Close</property></emphasis> button</para></listitem>
-</itemizedlist>
-</section>
-<section id="EditingTheFormBean">
-<?dbhtml filename="EditingTheFormBean.html"?>
-
-<title>Editing the Form Bean</title>
-<itemizedlist>
-<listitem><para>Right-click the <emphasis><property moreinfo="none">/greeting</property></emphasis> action again and select Open Form-bean Source to open the GetNameForm.java file for editing</para></listitem>
-<listitem><para>Change the class that it extends from: <emphasis><property moreinfo="none">org.apache.struts.action.ActionForm</property></emphasis> to <emphasis><property moreinfo="none">org.apache.struts.validator.ValidatorForm</property></emphasis></para></listitem>
-<listitem><para>Comment out a validate method</para></listitem>
-</itemizedlist>
-<para>The file should now look like this:</para>
-<programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
-import javax.servlet.http.HttpServletRequest;
-import org.apache.struts.action.ActionErrors;
-import org.apache.struts.action.ActionMapping;
-public class GetNameForm extends
-
-org.apache.struts.validator.ValidatorForm
-{
-
- private String name = "";
-
- /**
- * @return Returns the name.
- */
- public String getName()
- {
- return name;
- }
-
- /**
- * @param name The name to set.
- */
- public void setName(String name)
- {
- this.name = name;
- }
-
- public GetNameForm ()
- {
- }
-
- public void reset(ActionMapping actionMapping,
- HttpServletRequest request)
- {
- this.name = "";
- }
-
- // public ActionErrors validate(ActionMapping actionMapping,
- // HttpServletRequest request)
- //{
- // ActionErrors errors = new ActionErrors();
- // return errors;
- // }
- }
-]]></programlisting>
-
-<itemizedlist>
-<listitem><para>Select <emphasis><property moreinfo="none">File > Save All </property></emphasis>from the menu bar</para></listitem>
-<listitem><para>Reload the application into JBoss AS by clicking on the "Change Time Stamp" icon (a finger pointing with a little star) in the toolbar</para></listitem>
-<listitem><para>Run the application</para></listitem>
-<listitem><para>In the browser window, click on the "Say Hello!" button without having entered any name in the form</para></listitem>
-</itemizedlist>
-<para>The error message should appear in a refreshed version of the form.</para>
-</section>
-
-</chapter>
-
-<chapter id="relevant_resources" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/struts/docs/struts_tools_tutorial/en/modules/relevant_resources.xml" xreflabel="relevant_resources">
- <?dbhtml filename="relevant_resources.html"?>
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Struts</keyword>
- <keyword>Struts Application</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Other Relevant Resources on the topic</title>
-
- <para>Our reference: <ulink url="../../struts_tools_ref_guide/html_single/index.html">Struts Tools Reference Guide</ulink></para>
- <para>Apache Struts: <ulink url="http://struts.apache.org/">Struts Technology</ulink></para>
- <para>Struts 2: <ulink url="http://struts.apache.org/2.x/">Apache Struts 2</ulink></para>
- <para>Get Started: <ulink url="http://struts.apache.org/2.x/docs/home.html">Struts Getting
- Started</ulink></para>
- <para>Struts on IBM: <ulink url="http://www.ibm.com/developerworks/library/j-struts/">Struts -
- An open-source MVC implementation</ulink></para>
- <para>FAQ: <ulink url="http://struts.apache.org/2.x/docs/faqs.html">Struts FAQ</ulink></para>
- <para>Download: <ulink url="http://struts.apache.org/download.cgi#struts206">Release of Apache
- Struts</ulink></para>
-
- <para>Thus, this tutorial should help you to execute the hole development circle for building a
- sample Struts-based Web application using <property moreinfo="none">JBoss Tools</property> bundle of Eclipse
- plugins starting from organizing a new Struts project and ending with the running and
- deploying it onto the <property moreinfo="none">JBoss Server</property>.</para>
-
- <para>To find out all the features of <property moreinfo="none">JBoss Tools</property> for working with Struts
- refer to our <ulink url="../../struts_tools_ref_guide/html_single/index.html">Struts Tools Reference Guide</ulink>. If you
- still have questions you are always welcome on <ulink url="http://www.jboss.com/index.html?module=bb&op=viewforum&f=201">JBoss
- Tools Forum</ulink>.</para>
-</chapter>
-
-
-
-</book>
+]><book xmlns:diffmk="http://diffmk.sf.net/ns/diff">
+
+ <bookinfo>
+ <title>Struts Tools Tutorial</title>
+ <corpauthor>
+ <inlinemediaobject>
+ <imageobject role="fo">
+ <imagedata fileref="images/jbosstools_logo.png" format="PNG"></imagedata>
+ </imageobject>
+ <imageobject role="html">
+ <imagedata></imagedata>
+ </imageobject>
+ </inlinemediaobject>
+ </corpauthor>
+ <author><firstname>Anatoly</firstname><surname>Fedosik</surname></author>
+ <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
+ <author><firstname>Svetlana</firstname><surname>Mukhina</surname><email>smukhina(a)exadel.com</email></author>
+
+ <copyright>
+ <year>2007</year>
+ <year>2008</year>
+ <year>2009</year>
+ <year>2010</year>
+ <holder>JBoss by Red Hat</holder>
+ </copyright>
+ <releaseinfo><diffmk:wrapper diffmk:change="changed">
+ Version: 3.1.0.GA
+ </diffmk:wrapper></releaseinfo>
+
+<abstract>
+ <title></title>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/struts_tools_tutoria...">PDF version</ulink>
+ </para>
+</abstract>
+
+
+ </bookinfo>
+
+ <toc></toc>
+
+
+<chapter id="introduction" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/introduction.xml" xreflabel="introduction">
+ <?dbhtml filename="introduction.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse</keyword>
+ <keyword>Java</keyword>
+ <keyword>JBoss</keyword>
+ </keywordset>
+ </chapterinfo>
+ <title>Introduction</title>
+ <para>The following chapters describe how to deal with classic/old style of Struts development. We
+ recommend users to use <ulink url="../../seam/html_single/index.html">JBoss Seam</ulink> to
+ simplify development, but until then you can read about classical Struts usage here.</para>
+
+ <para>We are going to show you how to create a simple <emphasis>
+ <property moreinfo="none">Struts application</property>
+ </emphasis> using the JBoss Tools. The completed application will ask a user to enter
+ a name and click a button. The resulting new page will display the familiar message,
+ "Hello <name>!"</para>
+ <para>This document will show you how to create such an application from the beginning, along the
+ way demonstrating some of the powerful features of JBoss Tools. With the help of our tutorial you will design the
+ application, generate stub code for the application, fill in the stub coding, compile the
+ application, and finally run it all from inside the Eclipse.</para>
+
+ <section>
+ <title>Key Features Struts Tools</title>
+
+ <para>For a start, we propose you to look through the table of main features of Struts
+ Tools:</para>
+ <table>
+
+ <title>Key Functionality of Struts Tools</title>
+ <tgroup cols="2">
+
+ <colspec align="left" colnum="1" colwidth="2*"></colspec>
+ <colspec colnum="2" colwidth="4*"></colspec>
+
+
+ <thead>
+ <row>
+ <entry>Feature</entry>
+ <entry>Benefit</entry>
+
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry><para>Struts Support</para></entry>
+ <entry><para>Step-by-step wizards for creating a new struts project with a number
+ of predefined templates, importing existing ones and adding struts
+ capabilities to non-struts web projects.</para></entry>
+
+ </row>
+
+ <row>
+ <entry><para>Support for Struts Configuration File</para></entry>
+ <entry><para>Working on file using three modes: diagram, tree and source.
+ Synchronization between the modes and full control over the code. Easy
+ moving around the diagram using the Diagram Navigator. Working with
+ struts projects that have multiple modules. Possibility to use Struts
+ configuration file debugger allowing to set break points on struts
+ diagram and then launch the server in debug mode.</para></entry>
+
+ </row>
+
+ <row>
+ <entry><para>Support for Struts modules</para></entry>
+ <entry><para>A Struts module (struts-config.xml) is automatically created while
+ creating a new project. There is also possibility to add new ones or edit
+ already existing modules in your existing project or while importing Struts project.</para></entry>
+
+ </row>
+
+ <row>
+ <entry><para>Verification and Validation</para></entry>
+ <entry><para>All occurring errors will be immediately reported by verification
+ feature, no matter in what view you are working. Constant validation and
+ errors checking allows to catch many of the errors during development
+ process that significantly reduces development time.</para></entry>
+
+
+ </row>
+ </tbody>
+ </tgroup>
+ </table>
+ </section>
+
+
+
+ <section>
+ <title>Other relevant resources on the topic</title>
+
+ <para>All JBoss Developer Studio/JBoss Tools release documentation you can find at<ulink url="http://docs.jboss.org/tools/">http://docs.jboss.org/tools</ulink> in the corresponding release directory.</para>
+ <para>The latest documentation builds are available at <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">http://download.jboss.org/jbosstools/nightly-docs</ulink>.</para>
+
+ </section>
+
+</chapter>
+
+
+<chapter id="struts_application" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/struts_application.xml" xreflabel="struts_application">
+ <?dbhtml filename="struts_application.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Application</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Creating a Simple Struts Application</title>
+
+ <para>Firstly, we assume that you have already launched Eclipse with <property moreinfo="none">JBoss Tools</property> installed and
+ also that the <property moreinfo="none">Web Development perspective</property> is the current perspective. (If not, make it
+ active by selecting <emphasis>
+ <property moreinfo="none">Window > Open Perspective > Other > Web
+ Development</property>
+ </emphasis> from the menu bar.)</para>
+
+ <section id="StartingUp">
+ <title>Starting Up</title>
+ <para>We are first going to create a new project for the application.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Go to the menu bar and select <emphasis>
+ <property moreinfo="none">File > New > Struts Project</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Next enter "StrutsHello" as the project name</para>
+ </listitem>
+ <listitem>
+ <para>Leave everything else as it is, and click <emphasis>
+ <property moreinfo="none">Next</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>If you have server runtime already defined, just pass to next point. Otherwise in the <emphasis>
+ <property moreinfo="none">Runtime</property></emphasis> section click the <emphasis>
+ <property moreinfo="none">New</property></emphasis> button and target at needed server runtime environment. Click <emphasis>
+ <property moreinfo="none">Finish</property>.</emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Click <emphasis>
+ <property moreinfo="none">Next</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Make sure that <emphasis>
+ <property moreinfo="none">struts-bean.tld</property>
+ </emphasis>, <emphasis>
+ <property moreinfo="none">struts-html.tld</property>
+ </emphasis>, and <emphasis>
+ <property moreinfo="none">struts-logic.tld</property>
+ </emphasis> are checked in the list of included tag libraries and then hit <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <para>A "StrutsHello" node should appear in the <property moreinfo="none">Package
+ Explorer view</property>.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click the plus sign next to <emphasis>
+ <property moreinfo="none">StrutsHello</property>
+ </emphasis> to reveal the child nodes</para>
+ </listitem>
+ <listitem>
+ <para>Click the plus sign next to <emphasis>
+ <property moreinfo="none">WebContent</property>
+ </emphasis> under <emphasis>
+ <property moreinfo="none">StrutsHello</property></emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Click the plus sign next to <emphasis>
+ <property moreinfo="none">WEB-INF</property>
+ </emphasis> under <emphasis>
+ <property moreinfo="none">WebContent</property></emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Then, double-click on the <emphasis>
+ <property moreinfo="none">struts-config.xml</property>
+ </emphasis> node to display a diagram of the Struts application configuration
+ file in the editing area</para>
+ </listitem>
+ </itemizedlist>
+ <para>At this point, its empty except for the background grid lines.</para>
+ </section>
+
+ <section id="CreatingtheApplicationComponents">
+ <?dbhtml filename="CreatingtheApplicationComponents.html"?>
+ <title>Creating the Application Components</title>
+ <para>Now, we will design the application by creating the individual components as
+ placeholders first. (We don't have to complete all of the details inside the components
+ until afterwards.)</para>
+ <section id="CreatingJSPPagePlaceholders">
+ <title>Creating JSP Page Placeholders</title>
+ <para>Next, let's create and place two JSP pages. We will not write any code
+ for the files, but only create them as placeholders so that we can create links to
+ them in the diagram. We will write the code a little bit later.</para>
+ <section id="CreatingthePagePlaceholders">
+ <title>Creating the Page Placeholders</title>
+ <itemizedlist>
+ <listitem>
+ <para>Bring the <property moreinfo="none">Web Projects view</property> to the front of the <property moreinfo="none">Package Explorer view</property>
+ by selecting the <emphasis>
+ <property moreinfo="none">Web Projects</property>
+ </emphasis> tab next to that tab.</para>
+ </listitem>
+ <listitem>
+ <para>Right-click the <emphasis>
+ <property moreinfo="none">StrutsHello > WEB-ROOT (WebContent)</property>
+ </emphasis> folder in the <property moreinfo="none">Web Projects view</property> and select <emphasis>
+ <property moreinfo="none">New > Folder...</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Enter <emphasis>
+ <property moreinfo="none">pages</property>
+ </emphasis> for a folder name and click <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+
+ <listitem>
+ <para>We will keep our presentation files in this folder</para>
+ </listitem>
+
+ <listitem>
+ <para>Right-click the <emphasis>
+ <property moreinfo="none">pages</property></emphasis> folder and select <emphasis>
+ <property moreinfo="none">New > File > JSP...</property>
+ </emphasis>
+ </para>
+ </listitem>
+ <listitem>
+ <para>For Name type in <emphasis>
+ <property moreinfo="none">inputname</property>
+ </emphasis> (the JSP extension will be automatically added to the file),
+ for Template select <emphasis>
+ <property moreinfo="none">StrutsForm</property>
+ </emphasis> and then click on the <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis> button</para>
+ </listitem>
+ <listitem>
+ <para>Right-click the <emphasis>
+ <property moreinfo="none">pages</property></emphasis> folder again and select <emphasis>
+ <property moreinfo="none">New > File > JSP...</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>For Name type in <emphasis>
+ <property moreinfo="none">greeting</property>
+ </emphasis>, for Template leave as <emphasis>
+ <property moreinfo="none">Blank</property>,</emphasis> and then click on the <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis> button</para>
+ </listitem>
+ </itemizedlist>
+ <para>Just leave these files as is for now.</para>
+ </section>
+ <section id="PlacingthePagePlaceholders">
+ <title>Placing the Page Placeholders</title>
+ <para>Lets now place the two pages just created on the diagram.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">struts-config.xml</property>
+ </emphasis> tab in the editing area to bring the diagram to the
+ front</para>
+ </listitem>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">inputname.jsp</property>
+ </emphasis> page in the <property moreinfo="none">Web Projects view</property>, drag it onto the diagram, and
+ drop it</para>
+ </listitem>
+ <listitem><para>Click on the <emphasis>
+ <property moreinfo="none">greeting.jsp</property>
+ </emphasis> page in the <property moreinfo="none">Web Projects view</property>, drag it onto the diagram, and
+ drop it to the right of the <emphasis>
+ <property moreinfo="none">/pages/inputname.jsp</property>
+ </emphasis> icon with some extra space</para></listitem>
+ </itemizedlist>
+ <para>You should now have two JSP pages in the diagram.</para>
+ </section>
+ </section>
+ <section id="CreatinganActionMappings">
+ <title>Creating an Action Mappings</title>
+ <para>Using a context menu on the diagram, we are next going to create an Action
+ mapping.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Right-click between the two icons and select <emphasis>
+ <property moreinfo="none">New > Action</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Enter the following values:</para>
+ </listitem>
+ </itemizedlist>
+ <table>
+ <title>Action values</title>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry>path</entry>
+ <entry>/greeting</entry>
+ </row>
+ <row>
+ <entry>name</entry>
+ <entry>GetNameForm</entry>
+ </row>
+ <row>
+ <entry>scope</entry>
+ <entry>request</entry>
+ </row>
+ <row>
+ <entry>type</entry>
+ <entry>sample.GreetingAction</entry>
+ </row>
+ <row>
+ <entry>validate</entry>
+ <entry><leave blank></entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </table>
+ <para>("GetNameForm" is the name for a form bean that we will create
+ later.)</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+ </itemizedlist>
+
+ <para>The <emphasis>
+ <property moreinfo="none">/greeting</property>
+ </emphasis> action should appear in four places, in the diagram, under the
+ <emphasis>
+ <property moreinfo="none">action-mappings</property></emphasis> node, under the <emphasis>
+ <property moreinfo="none">struts-config.xml</property></emphasis> node in Tree view, in <property moreinfo="none">Web Projects
+ view</property> and in the <property moreinfo="none">Outline view</property>. Also, note the asterisk to the right of the name,
+ <emphasis>
+ <property moreinfo="none">struts-config.xml</property>,</emphasis> in the <property moreinfo="none">Outline view</property> showing that the file has been changed, but
+ not saved to disk.</para>
+ </section>
+ <section id="CreatingaLink">
+ <title>Creating a Link</title>
+ <para>Let's now create a link from the <emphasis>
+ <property moreinfo="none">inputname.jsp</property></emphasis> page to the action.</para>
+ <itemizedlist>
+ <listitem>
+ <para>On the left-hand side of the diagram in the column of icons, click on the Create New Connection
+ icon( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_1.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject>).</para>
+ </listitem>
+ </itemizedlist>
+ <itemizedlist>
+ <listitem>
+ <para>In the connect-the-components mode you are in now, click on the <emphasis>
+ <property moreinfo="none">/pages/inputname.jsp</property>
+ </emphasis> icon in the diagram and then click on the <emphasis>
+ <property moreinfo="none">/greeting</property>
+ </emphasis> action</para>
+ </listitem>
+ </itemizedlist>
+ <para>A link will be created from the page to the action.</para>
+ </section>
+ <section id="CreatingaForward">
+ <title>Creating a Forward</title>
+ <para>Next, we are going to create a forward for the action.</para>
+ <itemizedlist>
+ <listitem>
+ <para>On the left-hand side of the diagram in the column of icons, click on
+ the Create New Connection
+ icon( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_1.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject>), again.</para>
+ </listitem>
+ </itemizedlist>
+
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">/greeting</property>
+ </emphasis> action icon in the diagram and then click on the <emphasis>
+ <property moreinfo="none">pages/greeting.jsp</property>
+ </emphasis> icon</para>
+ </listitem>
+ <listitem>
+ <para>That's it. A link will be drawn from the actions new greeting
+ forward to the <emphasis>
+ <property moreinfo="none">greeting.jsp</property></emphasis> JSP page. Note that the forwards name will be
+ set based on the name of the target JSP file name. If you don't
+ like it, you can easily change it</para>
+ </listitem>
+ <listitem>
+ <para>Select the <emphasis>
+ <property moreinfo="none">Tree</property>
+ </emphasis> tab at the bottom of the editor window (between Diagram and
+ Source)</para>
+ </listitem>
+ <listitem>
+ <para>Expand the <emphasis>
+ <property moreinfo="none">struts-config.xml/action-mappings/ /greeting</property>
+ </emphasis> node and then select the greeting forward</para>
+ </listitem>
+ <listitem>
+ <para>In the Properties Editor to the right, change the text to
+ "sayHello" in the <emphasis>
+ <property moreinfo="none">Name</property></emphasis> field</para>
+ </listitem>
+ <listitem>
+ <para>Select the <emphasis>
+ <property moreinfo="none">Diagram</property>
+ </emphasis> tab at the bottom of the editor window and see how the diagram
+ is also updated to reflect the change</para>
+ </listitem>
+ </itemizedlist>
+ </section>
+ <section id="CreatingaGlobalForward">
+ <title>Creating a Global Forward</title>
+ <para>One last component that we need to create in the diagram is a global forward.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Somewhere in the top-left corner of diagram, right-click and select <emphasis>
+ <property moreinfo="none">New > Global Forward</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Enter <emphasis>
+ <property moreinfo="none">getName</property>
+ </emphasis> in the <emphasis>
+ <property moreinfo="none">Name</property></emphasis> field</para>
+ </listitem>
+ <listitem>
+ <para>Select the <emphasis>
+ <property moreinfo="none">Change...</property>
+ </emphasis>button for Path</para>
+ </listitem>
+ <listitem>
+ <para>In the Edit Path window, switch to the <emphasis>
+ <property moreinfo="none">Pages</property>
+ </emphasis> tab</para>
+ </listitem>
+ <listitem>
+ <para>Expand the <emphasis>
+ <property moreinfo="none">StrutsHello > WEB-ROOT (WebContent) > pages</property>
+ </emphasis> node and then select the inputname.jsp page</para>
+ </listitem>
+ <listitem>
+ <para>Click <emphasis>
+ <property moreinfo="none">Ok</property>
+ </emphasis>.</para>
+ </listitem>
+ <listitem>
+ <para>Leave the rest of the fields blank and click <emphasis>
+ <property moreinfo="none">OK</property>
+ </emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <para>A forward object now appears on the diagram and also in the global-forwards folder
+ in the Outline view.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Tidy up the diagram, by clicking and dragging around each icon, so that
+ the diagram looks something like this:</para>
+ </listitem>
+ </itemizedlist>
+ <figure float="0">
+ <title>Diagram View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+ <section id="CreatingaFormBean">
+ <title>Creating a Form Bean</title>
+ <para>One last thing that we need to do is to create a form bean.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Switch to the Tree viewer in the editor for the <emphasis>
+ <property moreinfo="none">struts-config.xml</property></emphasis> file, by
+ selecting the <emphasis>
+ <property moreinfo="none">Tree</property>
+ </emphasis> tab at the bottom of the editor window</para>
+ </listitem>
+ <listitem>
+ <para>Right-click <emphasis>
+ <property moreinfo="none">struts-config.xml > form-beans</property>
+ </emphasis> and select Create Form Bean</para>
+ </listitem>
+ <listitem>
+ <para>Enter <emphasis>
+ <property moreinfo="none">GetNameForm</property>
+ </emphasis> in the name field and <emphasis>
+ <property moreinfo="none">sample.GetNameForm</property>
+ </emphasis> for type</para>
+ </listitem>
+ <listitem>
+ <para>Click <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>To save your changes to struts-config.xml, select <emphasis>
+ <property moreinfo="none">File > Save</property>
+ </emphasis> from the menu bar</para>
+ </listitem>
+ </itemizedlist>
+ <para>Note the disappearance of the asterisk next to the name, <emphasis>
+ <property moreinfo="none">struts-config.xml</property>.</emphasis></para>
+ </section>
+ </section>
+</chapter>
+
+<chapter id="generating_stub" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/generating_stub.xml" xreflabel="generating_stub">
+ <?dbhtml filename="generating_stub.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Application</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Generating Stub Coding</title>
+ <para>We are done with designing the application through the diagram. Now we need to write
+ code for the action component. We also need to write an action class for the <emphasis>
+ <property moreinfo="none">/greeting</property>
+ </emphasis> mapping along with a FormBean. To aid in the coding phase, JBoss Developer
+ Studio can generate Java class stubs for all of the components shown in the diagram.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Switch back to the diagram, by selecting the <emphasis>
+ <property moreinfo="none">Diagram</property>
+ </emphasis> tab at the bottom of the editor window</para>
+ </listitem>
+ <listitem>
+ <para>Right-click a blank space in the diagram and select <emphasis>
+ <property moreinfo="none">Generate Java Code</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Leave everything as is in the dialog box and click <emphasis>
+ <property moreinfo="none">Generate</property>
+ </emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <para>You should see a screen that says:</para>
+ <para>Generated classes: 2</para>
+ <para>Actions: 1</para>
+ <para>Form beans: 1</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <para>The Java files will be generated in a <emphasis>
+ <property moreinfo="none">JavaSource > sample</property>
+ </emphasis> folder that you can see in the <property moreinfo="none">Package Explorer view</property> under the
+ "StrutsHello" node. One Action stub and one FormBean stub will have
+ been generated.</para>
+ </chapter>
+
+<chapter id="coding_files" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/coding_files.xml" xreflabel="coding_files">
+ <?dbhtml filename="coding_files.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Application</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Coding the Various Files</title>
+ <para>We will now code both the Java stub classes just generated, the JSP files left in as
+ placeholders from previous steps, and a new start JSP page we will have to create.</para>
+ <section id="JavaStubClasses">
+ <title>Java Stub Classes</title>
+ <itemizedlist>
+ <listitem>
+ <para>To finish the two Java classes, switch to the <emphasis>
+ <property moreinfo="none">Package Explorer</property>
+ </emphasis> view and expand the <emphasis>
+ <property moreinfo="none">JavaSource > sample</property>
+ </emphasis> folder</para>
+ </listitem>
+ </itemizedlist>
+ <section id="GetNameForm.java">
+ <title>GetNameForm.java</title>
+ <itemizedlist>
+ <listitem>
+ <para>Double-click <emphasis>
+ <property moreinfo="none">GetNameForm.java</property>
+ </emphasis> for editing</para>
+ </listitem>
+
+ <listitem>
+ <para>You are looking at a Java stub class that was generated by JBoss
+ Tools. Now we are going to edit the file</para>
+ </listitem>
+
+ <listitem>
+ <para>Add the following attributes at the beginning of the class:</para>
+ </listitem>
+ </itemizedlist>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[private String name = "";
+]]></programlisting>
+
+ <itemizedlist>
+ <listitem>
+ <para>Inside the reset method, delete the TO DO and throw lines and
+ add:</para>
+ </listitem>
+ </itemizedlist>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[this.name = "";
+]]></programlisting>
+
+ <itemizedlist>
+ <listitem>
+ <para>Inside the validate method, delete the TO DO and throw lines and
+ add:</para>
+ </listitem>
+ </itemizedlist>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[ActionErrors errors = new ActionErrors();
+ return errors;
+]]></programlisting>
+
+ <itemizedlist>
+ <listitem>
+ <para>Right-click and select <emphasis>
+ <property moreinfo="none">Source > Generate Getters and Setters</property>
+ </emphasis>from the context menu</para>
+ </listitem>
+ <listitem>
+ <para>In the dialog box, check the check box for <emphasis>
+ <property moreinfo="none">name</property>,</emphasis>
+ select First method for Insertion point, and click on the <emphasis>
+ <property moreinfo="none">OK</property>
+ </emphasis> button</para>
+ </listitem>
+ </itemizedlist>
+ <para>The final <emphasis>
+ <property moreinfo="none">GetNameForm.java</property></emphasis> file should look like this:</para>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
+import javax.servlet.http.HttpServletRequest;
+import org.apache.struts.action.ActionErrors;
+import org.apache.struts.action.ActionMapping;
+
+public class GetNameForm extends org.apache.struts.action.ActionForm
+{
+
+ private String name = "";
+
+ public String getName()
+ {
+ return name;
+ }
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+
+ public GetNameForm()
+ {
+ }
+
+ public void reset(ActionMapping actionMapping, HttpServletRequest request)
+ {
+ this.name = "";
+ }
+
+ public ActionErrors validate(ActionMapping actionMapping,
+ HttpServletRequest request)
+ {
+ ActionErrors errors = new ActionErrors();
+ return errors;
+ }
+}
+]]></programlisting>
+
+ <itemizedlist>
+ <listitem>
+ <para>Save the file</para>
+ </listitem>
+ </itemizedlist>
+ </section>
+ <section id="GreetingAction.java">
+ <title>GreetingAction.java</title>
+ <itemizedlist>
+ <listitem>
+ <para>Open <emphasis>
+ <property moreinfo="none">GreetingAction.java</property></emphasis> for editing</para>
+ </listitem>
+ <listitem>
+ <para>Inside the execute method, delete the TO DO lines and add the
+ following:</para>
+ </listitem>
+ </itemizedlist>
+
+ <programlisting format="linespecific" role="JAVA"><![CDATA[String name = ((GetNameForm)form).getName();
+String greeting = "Hello, "+name+"!";
+((GetNameForm)form).setName(greeting);
+return mapping.findForward(FORWARD_sayHello);
+]]></programlisting>
+
+ <para>The final version of <emphasis>
+ <property moreinfo="none">GreetingAction.java</property></emphasis> should look like this:</para>
+
+ <programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionForward;
+import org.apache.struts.action.ActionMapping;
+
+public class GreetingAction extends org.apache.struts.action.Action
+{
+
+ // Global Forwards
+ public static final String GLOBAL_FORWARD_getName = "getName";
+
+ // Local Forwards
+ public static final String FORWARD_sayHello = "sayHello";
+
+ public GreetingAction()
+ {
+ }
+ public ActionForward execute(ActionMapping mapping, ActionForm form,
+ HttpServletRequest request, HttpServletResponse response) throws Exception
+ {
+ String name = ((GetNameForm)form).getName();
+ String greeting = "Hello, "+name+"!";
+ ((GetNameForm)form).setName(greeting);
+ return mapping.findForward(FORWARD_sayHello);
+ }
+}
+]]></programlisting>
+ <itemizedlist>
+ <listitem>
+ <para>Save the file</para>
+ </listitem>
+ <listitem>
+ <para>Close the editors for the two Java files</para>
+ </listitem>
+ </itemizedlist>
+ <para>The last thing left to do is to code the JSP files whose editors should still
+ be open from having been created as placeholders.</para>
+ </section>
+ </section>
+ <section id="JSPPages">
+ <title>JSP Pages</title>
+ <section id="inputname.jsp">
+ <title>inputname.jsp</title>
+ <para>In this page, the user will enter any name and click the <emphasis>
+ <property moreinfo="none">submit</property>
+ </emphasis> button. Then, the greeting action will be called through the form.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">inputname.jsp</property>
+ </emphasis> tab in the Editing area to bring its editor forward</para>
+ </listitem>
+ <listitem>
+ <para>In the Web Projects view, expand <emphasis>
+ <property moreinfo="none">StrutsHello > Configuration > default
+ > struts-config.xml > action-mappings</property>
+ </emphasis> and select <emphasis>
+ <property moreinfo="none">/greeting</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Drag it and drop it between the quotes for the <emphasis role="italic">
+ <property moreinfo="none">"action"</property>
+ </emphasis> attribute to the
+ <code><html:form></code>
+ element in the Source pane of the editor</para>
+ </listitem>
+ <listitem>
+ <para>Then type this text on a new line just below this line:</para>
+ <programlisting format="linespecific" role="XML"><![CDATA[Input name:
+ ]]></programlisting>
+ </listitem>
+
+ <listitem>
+ <para>Select the <emphasis>
+ <property moreinfo="none">Visual</property>
+ </emphasis> pane of the editor</para>
+ </listitem>
+ <listitem>
+ <para>Then, in the JBoss Tools Palette, expand the <emphasis>
+ <property moreinfo="none">Struts Form</property>
+ </emphasis> library, select <emphasis>
+ <property moreinfo="none">text</property>
+ </emphasis>, and drag it onto the box
+ <note>
+ <title>Note:</title>
+ <para>By default there are only four groups on the JBoss Tools
+ Palette. If you wish to make some group visible click the <emphasis>
+ <property moreinfo="none">Show/Hide</property>
+ </emphasis> button on the top of palette and in the prompted
+ dialog check the group (or groups) you want to be shown.</para>
+ </note>
+ </para>
+ </listitem>
+ </itemizedlist>
+ <figure float="0">
+ <title>JBoss Tools Palette</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <itemizedlist>
+ <listitem>
+ <para>In the Insert Tag dialog box, type in name for property and select <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>In the StrutsForm library in the <property moreinfo="none">JBoss Tools Palette</property>, select <emphasis>
+ <property moreinfo="none">submit</property>
+ </emphasis>, and drag it to right after the text box in the Visual pane
+ of the editor</para>
+ </listitem>
+ <listitem>
+ <para>Right-click the <emphasis>
+ <property moreinfo="none">submit</property>
+ </emphasis> button and select
+ <code><html:submit></code>
+ Attributes from the context menu</para>
+ </listitem>
+ <listitem>
+ <para>In the Attributes dialog box, select the <emphasis>
+ <property moreinfo="none">value</property>
+ </emphasis> field and type in "Say Hello!" for its
+ value</para>
+ </listitem>
+ </itemizedlist>
+ <para>After tidying the page source, the Editor window for the file should look
+ something like this:</para>
+ <figure float="0">
+ <title>Editor Window</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_4.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+ <section id="greeting.jsp">
+ <title>greeting.jsp</title>
+ <para>Next, we will fill in the result page.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">greeting.jsp</property>
+ </emphasis> tab in the Editing area to bring its editor forward</para>
+ </listitem>
+ <listitem>
+ <para>Type in the following code:</para>
+ </listitem>
+ </itemizedlist>
+ <programlisting format="linespecific" role="XML"><![CDATA[<html>
+<head>
+ <title>Greeting</title>
+</head>
+ <body>
+ <p>
+ </p>
+ </body>
+</html>
+]]></programlisting>
+
+ <para>To complete editing of this file, we will use macros from the <property moreinfo="none">JBoss Tools
+ Palette</property>. This palette is a view that should be available to the right of the
+ editing area.</para>
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">Struts Common</property>
+ </emphasis> folder in the <property moreinfo="none">JBoss Tools Palette</property> to open it</para>
+ </listitem>
+ <listitem>
+ <para>Position the cursor at the beginning of the <emphasis>
+ <property moreinfo="none">greeting.jsp</property></emphasis> file in the
+ Source pane and then click on <emphasis>
+ <property moreinfo="none">bean taglib</property></emphasis> in the <property moreinfo="none">JBoss Tools
+ Palette</property></para>
+ </listitem>
+ </itemizedlist>
+ <para>This will insert the following line at the top of the file:</para>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[
+<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
+]]></programlisting>
+ <itemizedlist>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">Struts Bean</property>
+ </emphasis> folder in the <property moreinfo="none">JBoss Tools Palette</property> to open it</para>
+ </listitem>
+ <listitem>
+ <para>Position the cursor inside the
+ <code><p></code>
+ element</para>
+ </listitem>
+ <listitem>
+ <para>Click on <emphasis>
+ <property moreinfo="none">write</property></emphasis> in the <property moreinfo="none">JBoss Tools Palette</property></para>
+ </listitem>
+ <listitem>
+ <para>Type in "GetNameForm" for the <emphasis role="italic">
+ <property moreinfo="none">name</property>
+ </emphasis> attribute and add a <emphasis role="italic">
+ <property moreinfo="none">property</property>
+ </emphasis> attribute with "name" as its
+ value</para>
+ </listitem>
+ </itemizedlist>
+ <para>The editor should now look like this:</para>
+ <figure float="0">
+ <title>Editor Window</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_5.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+ <section id="index.jsp">
+ <title>index.jsp</title>
+ <para>Finally, we will need to create and edit an <emphasis>
+ <property moreinfo="none">index.jsp</property></emphasis> page. This page will use
+ a Struts forward to simply redirect us to the getName global forward.</para>
+ <itemizedlist>
+ <listitem>
+ <para>In the Web Projects view, right-click on <emphasis>
+ <property moreinfo="none">StrutsHello > WEB-ROOT(WebContent)</property>
+ </emphasis> node and select <emphasis>
+ <property moreinfo="none">New > File > JSP</property>
+ </emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Type <emphasis>
+ <property moreinfo="none">index</property></emphasis> for Name and click on the <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis> button</para>
+ </listitem>
+ <listitem>
+ <para>On the <property moreinfo="none">JBoss Tools Palette</property>, select the <emphasis>
+ <property moreinfo="none">Struts Common</property>
+ </emphasis> folder of macros by clicking on it in the palette</para>
+ </listitem>
+ <listitem>
+ <para>Click on the <emphasis>
+ <property moreinfo="none">logic taglib</property></emphasis> icon</para>
+ </listitem>
+ <listitem>
+ <para>Press the <emphasis>
+ <property moreinfo="none">Enter</property>
+ </emphasis> key in the editor to go to the next line</para>
+ </listitem>
+ <listitem>
+ <para>Back on the palette, select the <emphasis>
+ <property moreinfo="none">Struts Logic</property>
+ </emphasis> folder of macros</para>
+ </listitem>
+ <listitem>
+ <para>Click on <emphasis>
+ <property moreinfo="none">redirect</property></emphasis></para>
+ </listitem>
+ <listitem>
+ <para>Delete the ending tag, put a forward slash in front of the closing
+ angle bracket, and type "forward=getName" in front of
+ the slash</para>
+ </listitem>
+ </itemizedlist>
+ <para>The finished code for the page is shown below:</para>
+ <programlisting format="linespecific" role="JAVA"><![CDATA[<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
+<logic:redirect forward="getName"/>
+]]></programlisting>
+ <itemizedlist>
+ <listitem>
+ <para>To save all the edits to files, select <emphasis>
+ <property moreinfo="none">File>Save All</property>
+ </emphasis> from the menu bar</para>
+ </listitem>
+ </itemizedlist>
+ </section>
+ </section>
+ </chapter>
+
+<chapter id="compiling_and_running" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/compiling_and_running.xml" xreflabel="compiling_and_running">
+ <?dbhtml filename="compiling_and_running.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Application</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Compiling the Classes and Running the Application</title>
+
+ <para>As this is the Eclipse environment, no explicit compilation step is required. By
+ default, Eclipse compiles as you go.</para>
+
+ <para>Thus at this point everything is ready for running our application without having to leave JBoss
+ Developer Studio by using the JBoss Application Server engine that comes with the JBoss
+ Developer Studio. For controlling JBoss AS within JBoss Developer Studio, there is JBoss
+ Server view.</para>
+ <figure float="0">
+ <title>JBoss Server Panel</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_application/struts_application_6.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <itemizedlist>
+ <listitem>
+ <para>Start up JBoss AS by clicking on the icon in JBoss Server view. (If JBoss AS
+ is already running, stop it by clicking on the red icon and then start it again.
+ Remember, the Struts run-time requires restarting the servlet engine when any
+ changes have been made.)</para>
+ </listitem>
+ <listitem>
+ <para>After the messages in the Console tabbed view stop scrolling, JBoss AS is
+ available. At this point, right-click on the getName global forward in the
+ struts-config.xml diagram view and select Run on Server.</para>
+ </listitem>
+ </itemizedlist>
+ <para>The browser should appear with the application started.</para>
+ </chapter>
+
+<chapter id="struts_validation" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/struts_validation.xml" xreflabel="struts_validation">
+ <?dbhtml filename="struts_validation.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Developer Studio</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Validation</keyword>
+ </keywordset>
+ </chapterinfo>
+<title>Struts Validation Examples</title>
+
+<para><property moreinfo="none">Validation</property> of input is an important part of any Web application. All Apache Jakarta frameworks,
+including Struts, can use a common Jakarta Validation Framework for streamlining this aspect of Web
+application development. The Validation Framework allows you to define validation rules and then apply these rules on the client-side or the server-side.</para>
+
+ <para>JBoss Developer Studio makes using the <property moreinfo="none">Validation Framework</property> in Struts even easier with the help of a specialized editor for the XML files that controls validation in a project. In this document, we'll show you how this all works by creating some simple client-side validation and server-side validation examples.</para>
+
+<section id="StartingPoint">
+<?dbhtml filename="StartingPoint.html"?>
+<title>Starting Point</title>
+<para>The example assumes that you have already created our sample "StrutsHello" application from the
+Getting Started Guide for Creating a Struts Application. You should have the JBoss Developer Studio perspective
+ open on this StrutsHello project.</para>
+</section>
+
+<section id="DefiningTheValidationRule">
+<?dbhtml filename="DefiningTheValidationRule.html"?>
+<title>Defining the Validation Rule</title>
+<para>In these steps you will set up the validation that can be used for either client-side or
+server side validation. You need to enable validation as a part of the project, define an error message, and tie it into an appropriate part of the application.</para>
+
+<itemizedlist>
+<listitem><para>Right-click on a "plug-ins" node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml</property></emphasis> node in the Web Projects view and select <emphasis><property moreinfo="none">Create Special Plugin > Validators</property></emphasis> from the context menu</para></listitem>
+<listitem><para>Further down in the Web Projects view, right-click on the
+<emphasis><property moreinfo="none">StrutsHello > ResourceBundles</property></emphasis> node and select <emphasis><property moreinfo="none"> New > Properties File...</property></emphasis>from the context menu</para></listitem>
+<listitem><para>In the dialog box, click on the <emphasis><property moreinfo="none">Browse...</property></emphasis>button next to the Folder field, expand the
+ JavaSource folder in this next dialog box, select the sample subfolder, and click on the <emphasis><property moreinfo="none">OK</property></emphasis> button</para></listitem>
+ <listitem><para>Back in the first dialog box, type in "applResources" for the Name field and click on the <emphasis><property moreinfo="none">Finish</property></emphasis> button</para></listitem>
+<listitem><para>Right-click on a newly created file and select <emphasis><property moreinfo="none">Add > Default Error Messages</property></emphasis>
+ from the context menu</para></listitem>
+
+<listitem><para>Drag up the sample.applResources icon until you can drop it on the resources folder under struts-config.xml</para></listitem>
+<listitem><para>Select<emphasis><property moreinfo="none"> File > Save </property></emphasis>All from the menu bar</para></listitem>
+<listitem><para>Select validation.xml under the <emphasis><property moreinfo="none">StrutsHello > Validation</property></emphasis> node and double-click it to open it with the JBoss Tools XML Editor</para></listitem>
+<listitem><para>Here you must create a Formset.</para></listitem>
+<listitem><para>In the validation.xml file editor click the button <emphasis><property moreinfo="none">Create Formset</property></emphasis> on the panel <emphasis><property moreinfo="none">Formsets</property></emphasis></para></listitem>
+<listitem><para>In the dialog <emphasis><property moreinfo="none">Add Formset</property></emphasis> fill the fields <emphasis><property moreinfo="none">Language</property></emphasis> and <emphasis><property moreinfo="none">Country</property></emphasis> or just leave them empty to create a default formset. Click <emphasis><property moreinfo="none">OK</property></emphasis></para></listitem>
+</itemizedlist>
+<figure float="0">
+ <title>Create Formset</title>
+<mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_validation/struts_validation.png"></imagedata>
+ </imageobject>
+</mediaobject>
+</figure>
+<itemizedlist>
+<listitem><para>Expand the "form-beans" node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml node.</property></emphasis> Then, drag the form bean "GetNameForm" and drop it onto a formset in the <property moreinfo="none">XML</property> Editor</para></listitem>
+<listitem><para>In the Validation Editor, expand the formset node, right-click GetNameForm, and select <emphasis><property moreinfo="none">Create Field...</property></emphasis> from the context menu</para></listitem>
+<listitem><para>Enter a name for Property in the dialog box. A new property will be created:</para></listitem>
+</itemizedlist>
+<figure float="0">
+ <title>New Property Is Added</title>
+<mediaobject>
+ <imageobject>
+ <imagedata fileref="images/struts_validation/struts_validation_2.png"></imagedata>
+ </imageobject>
+</mediaobject>
+</figure>
+<itemizedlist>
+<listitem><para>In the Properties view for the name field to the right of the "tree" for the validation.xml file, click on the <emphasis><property moreinfo="none">Change...</property></emphasis>button next to the Depends entry field</para></listitem>
+<listitem><para>In the displayed double list, select <emphasis><property moreinfo="none">required</property></emphasis> from the left list and then click <emphasis><property moreinfo="none">Add</property></emphasis></para></listitem>
+ <listitem><para>Click <emphasis><property moreinfo="none">Ok</property></emphasis></para></listitem>
+<listitem><para>Right-click name and select <emphasis><property moreinfo="none">Add Arg...</property></emphasis> from the context menu</para></listitem>
+<listitem><para>In the Add Arg dialog box, click on the <emphasis><property moreinfo="none">Change...</property></emphasis>button next to the <emphasis><property moreinfo="none">Key</property></emphasis> field</para></listitem>
+ <listitem><para>In the Key dialog box that appears now, click on the <emphasis><property moreinfo="none">Add</property></emphasis> button</para></listitem>
+ <listitem><para>Enter "name.required" in the Name field, and enter a person's name in the Value field</para></listitem>
+ <listitem><para>Click <emphasis><property moreinfo="none">Finish</property></emphasis>, then <emphasis><property moreinfo="none">Ok</property></emphasis>, and then <emphasis><property moreinfo="none">Ok</property></emphasis> again</para></listitem>
+<listitem><para>Select <emphasis><property moreinfo="none">File > Save All</property></emphasis> from the menu bar</para></listitem>
+</itemizedlist>
+</section>
+
+<section id="Client-SideValidation">
+<?dbhtml filename="Client-SideValidation.html"?>
+<title>Client-Side Validation</title>
+<para>Client-side <property moreinfo="none">validation</property> uses a scripting language (like JavaScript) running in the client browser to actually do the <property moreinfo="none">validation</property>. In a Struts application using the <property moreinfo="none">Validation</property> Framework, however, you don't actually have to do any of the script coding. The <property moreinfo="none">Validation</property> Framework handles this.</para>
+<para>To see how this works in our application, you'll just need to make a couple of modifications to one of the JSP files.</para>
+<itemizedlist>
+<listitem><para>Double-click inputname.jsp under <emphasis><property moreinfo="none">StrutsHello > WEB-ROOT(WebContent) > pages</property></emphasis> to open it for editing</para></listitem>
+<listitem><para>Find the tag near the top and hit Return to make a new line under it</para></listitem>
+ <listitem><para>In the JBoss Tools Palette view to the right, open the Struts HTML folder and click on the javascript tag</para></listitem>
+<listitem><para>Back in the editor, just in front of the closing slash for this inserted tag, hit Ctrl+Space and select "formName" from the prompting menu</para></listitem>
+<listitem><para>Over in the Web Projects view, select GetNameForm under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml > form-beans</property></emphasis> node, drag it, and drop it between the quotes in the editor</para></listitem>
+<listitem><para>Modify the <code><html:form></code> tag by inserting this attribute:</para></listitem>
+</itemizedlist>
+<programlisting format="linespecific" role="XML"><![CDATA[onsubmit="return validateGetNameForm(this)"
+]]></programlisting>
+<para></para>
+<para>The file should now look like this:</para>
+<programlisting format="linespecific" role="XML"><![CDATA[
+<%@ taglib uri="/WEB-INF/struts-html" prefix="html" %>
+
+<html:html >
+ <head>
+ <html:javascript formName="GetNameForm"/>
+ <title></title>
+ </head>
+ <body>
+ <html:form action="/greeting.do" onsubmit="return validateGetNameForm(this)">
+ Input name:<html:text property="name"/><html:submit value="Say Hello!"/>
+ </html:form>
+ </body>
+</html:html>
+]]></programlisting>
+<itemizedlist>
+<listitem><para>Select<emphasis><property moreinfo="none"> File > Save </property></emphasis>from the menu bar</para></listitem>
+<listitem><para>Start JBoss Application Server by clicking on its icon (a right-pointing arrow) in the toolbar</para></listitem>
+ <listitem><para>Click the Run icon(<inlinemediaobject> <imageobject>
+ <imagedata fileref="images/struts_validation/struts_validation_1.png"></imagedata>
+ </imageobject></inlinemediaobject>) or right click your project folder and select <emphasis><property moreinfo="none">Run As > Run on Server</property></emphasis></para></listitem>
+</itemizedlist>
+
+<itemizedlist><listitem><para>In the browser window, click on the "Say Hello!" button without having entered any name in the form</para></listitem></itemizedlist>
+<para>A JavaScript error message should be displayed in an alert box.</para>
+</section>
+<section id="Server-SideValidation">
+<?dbhtml filename="Server-SideValidation.html"?>
+<title>Server Side Validation</title>
+<para>Server side validation does the validation inside the application on the server. In a Struts application using the Validation Framework, you still don't have to do any of the actual validation coding. The Validation Framework handles this. You will though have to make a few changes to the JSP file you modified for client-side validation along with a change to an action and a few changes to the form bean class.</para>
+</section>
+
+<section id="EditingTheJSPFile">
+<?dbhtml filename="EditingTheJSPFile.html"?>
+<title>Editing the JSP File</title>
+<itemizedlist>
+<listitem><para>Reopen inputname.jsp for editing</para></listitem>
+<listitem><para>Delete the <emphasis role="italic"><property moreinfo="none">"onsubmit"</property></emphasis> attribute in the <code><html:form></code> element that you put in for client-side validation</para></listitem>
+
+<listitem><para>Add an <code><html:errors/></code> tag after the
+ <code><html:form></code>
+ tag</para></listitem>
+</itemizedlist>
+<para>The JSP file should now look like this:</para>
+
+ <programlisting format="linespecific" role="XML"><![CDATA[<%@ taglib uri="/WEB-INF/struts-html" prefix="html" %>
+<html:html >
+<head>
+ <html:javascript formName="GetNameForm"/>
+ <title></title>
+ </head>
+ <body>
+ <html:form action="/greeting.do" >Input name:<html:text property="name"/>
+ <html:submit value="Say Hello!"/>
+ </html:form>
+ <html:errors/>
+ </body>
+</html:html>
+]]></programlisting>
+
+</section>
+
+<section id="EditingTheAction">
+<?dbhtml filename="EditingTheAction.html"?>
+<title>Editing the Action</title>
+<itemizedlist>
+<listitem><para>In the Web Projects view, expand the node under the <emphasis><property moreinfo="none">StrutsHello > Configuration > default > struts-config.xml > action-mappings</property></emphasis> node, right-click the <emphasis><property moreinfo="none">/greeting</property></emphasis> action, and then select <emphasis><property moreinfo="none">Properties...</property></emphasis>from the context menu</para></listitem>
+
+ <listitem><para>In the Edit Properties window, insert the cursor into the value column for the input property and click on the <property moreinfo="none">...</property> button</para></listitem>
+
+ <listitem><para>In the dialog box, make sure the Pages tab is selected, select <emphasis><property moreinfo="none">StrutsHello > WEB-ROOT(WebContent) > pages > inputname.jsp</property></emphasis>, click the <emphasis><property moreinfo="none">Ok</property></emphasis> button, and then click on the <emphasis><property moreinfo="none">Close</property></emphasis> button</para></listitem>
+</itemizedlist>
+</section>
+<section id="EditingTheFormBean">
+<?dbhtml filename="EditingTheFormBean.html"?>
+
+<title>Editing the Form Bean</title>
+<itemizedlist>
+<listitem><para>Right-click the <emphasis><property moreinfo="none">/greeting</property></emphasis> action again and select Open Form-bean Source to open the GetNameForm.java file for editing</para></listitem>
+<listitem><para>Change the class that it extends from: <emphasis><property moreinfo="none">org.apache.struts.action.ActionForm</property></emphasis> to <emphasis><property moreinfo="none">org.apache.struts.validator.ValidatorForm</property></emphasis></para></listitem>
+<listitem><para>Comment out a validate method</para></listitem>
+</itemizedlist>
+<para>The file should now look like this:</para>
+<programlisting format="linespecific" role="JAVA"><![CDATA[package sample;
+import javax.servlet.http.HttpServletRequest;
+import org.apache.struts.action.ActionErrors;
+import org.apache.struts.action.ActionMapping;
+public class GetNameForm extends
+
+org.apache.struts.validator.ValidatorForm
+{
+
+ private String name = "";
+
+ /**
+ * @return Returns the name.
+ */
+ public String getName()
+ {
+ return name;
+ }
+
+ /**
+ * @param name The name to set.
+ */
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+
+ public GetNameForm ()
+ {
+ }
+
+ public void reset(ActionMapping actionMapping,
+ HttpServletRequest request)
+ {
+ this.name = "";
+ }
+
+ // public ActionErrors validate(ActionMapping actionMapping,
+ // HttpServletRequest request)
+ //{
+ // ActionErrors errors = new ActionErrors();
+ // return errors;
+ // }
+ }
+]]></programlisting>
+
+<itemizedlist>
+<listitem><para>Select <emphasis><property moreinfo="none">File > Save All </property></emphasis>from the menu bar</para></listitem>
+<listitem><para>Reload the application into JBoss AS by clicking on the "Change Time Stamp" icon (a finger pointing with a little star) in the toolbar</para></listitem>
+<listitem><para>Run the application</para></listitem>
+<listitem><para>In the browser window, click on the "Say Hello!" button without having entered any name in the form</para></listitem>
+</itemizedlist>
+<para>The error message should appear in a refreshed version of the form.</para>
+</section>
+
+</chapter>
+
+<chapter id="relevant_resources" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/struts/docs/struts_tools_tutorial/en/modules/relevant_resources.xml" xreflabel="relevant_resources">
+ <?dbhtml filename="relevant_resources.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Struts</keyword>
+ <keyword>Struts Application</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Other Relevant Resources on the topic</title>
+
+ <para>Our reference: <ulink url="../../struts_tools_ref_guide/html_single/index.html">Struts Tools Reference Guide</ulink></para>
+ <para>Apache Struts: <ulink url="http://struts.apache.org/">Struts Technology</ulink></para>
+ <para>Struts 2: <ulink url="http://struts.apache.org/2.x/">Apache Struts 2</ulink></para>
+ <para>Get Started: <ulink url="http://struts.apache.org/2.x/docs/home.html">Struts Getting
+ Started</ulink></para>
+ <para>Struts on IBM: <ulink url="http://www.ibm.com/developerworks/library/j-struts/">Struts -
+ An open-source MVC implementation</ulink></para>
+ <para>FAQ: <ulink url="http://struts.apache.org/2.x/docs/faqs.html">Struts FAQ</ulink></para>
+ <para>Download: <ulink url="http://struts.apache.org/download.cgi#struts206">Release of Apache
+ Struts</ulink></para>
+
+ <para>Thus, this tutorial should help you to execute the hole development circle for building a
+ sample Struts-based Web application using <property moreinfo="none">JBoss Tools</property> bundle of Eclipse
+ plugins starting from organizing a new Struts project and ending with the running and
+ deploying it onto the <property moreinfo="none">JBoss Server</property>.</para>
+
+ <para>To find out all the features of <property moreinfo="none">JBoss Tools</property> for working with Struts
+ refer to our <ulink url="../../struts_tools_ref_guide/html_single/index.html">Struts Tools Reference Guide</ulink>. If you
+ still have questions you are always welcome on
+ <ulink url="http://www.jboss.com/index.html?module=bb&op=viewforum&f=201">JBoss
+ Tools Forum</ulink>.</para>
+</chapter>
+
+
+
+</book>
Modified: branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/pom.xml
===================================================================
--- branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/pom.xml 2010-03-04 12:40:59 UTC (rev 20647)
+++ branches/jbosstools-3.1.x/struts/docs/struts_tools_tutorial/pom.xml 2010-03-04 12:44:41 UTC (rev 20648)
@@ -32,7 +32,7 @@
<profile>
<id>releaseJBDS</id>
<properties>
- <master>master_output.xml</master>
+ <master>master.xml</master>
<xsl-single>classpath:/xslt/com/jboss/tools/xhtml-single-release.xsl</xsl-single>
<xsl-chunked>classpath:/xslt/com/jboss/tools/xhtml-release.xsl</xsl-chunked>
<xsl-pdf>classpath:/xslt/com/jboss/tools/pdf.xsl</xsl-pdf>
14 years, 10 months
JBoss Tools SVN: r20647 - trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2010-03-04 07:40:59 -0500 (Thu, 04 Mar 2010)
New Revision: 20647
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java
Log:
JBIDE-5992: Inserting tag into selected element causes NullPointerException
issue is fixed
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java 2010-03-04 12:40:14 UTC (rev 20646)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/PageContextFactory.java 2010-03-04 12:40:59 UTC (rev 20647)
@@ -503,6 +503,8 @@
private void fillElReferencesForNode(IDOMNode node, XmlContextImpl context) {
if(Node.ELEMENT_NODE == node.getNodeType() || Node.TEXT_NODE == node.getNodeType()) {
IStructuredDocumentRegion regionNode = node.getFirstStructuredDocumentRegion();
+ if (regionNode == null)
+ return;
ITextRegionList regions = regionNode.getRegions();
for(int i=0; i<regions.size(); i++) {
ITextRegion region = regions.get(i);
14 years, 10 months
JBoss Tools SVN: r20646 - branches/jbosstools-3.1.x/as/docs/reference/en.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 07:40:14 -0500 (Thu, 04 Mar 2010)
New Revision: 20646
Modified:
branches/jbosstools-3.1.x/as/docs/reference/en/master.xml
branches/jbosstools-3.1.x/as/docs/reference/en/master_output.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Modified: branches/jbosstools-3.1.x/as/docs/reference/en/master.xml
===================================================================
--- branches/jbosstools-3.1.x/as/docs/reference/en/master.xml 2010-03-04 12:35:08 UTC (rev 20645)
+++ branches/jbosstools-3.1.x/as/docs/reference/en/master.xml 2010-03-04 12:40:14 UTC (rev 20646)
@@ -52,7 +52,7 @@
<holder>JBoss by Red Hat</holder>
</copyright>
<releaseinfo>
- Version: 2.1.0.CR1
+ Version: 2.1.0.GA
</releaseinfo>
<abstract>
<title/>
Modified: branches/jbosstools-3.1.x/as/docs/reference/en/master_output.xml
===================================================================
--- branches/jbosstools-3.1.x/as/docs/reference/en/master_output.xml 2010-03-04 12:35:08 UTC (rev 20645)
+++ branches/jbosstools-3.1.x/as/docs/reference/en/master_output.xml 2010-03-04 12:40:14 UTC (rev 20646)
@@ -49,7 +49,7 @@
<holder>JBoss by Red Hat</holder>
</copyright>
<releaseinfo><diffmk:wrapper diffmk:change="changed">
- Version: 2.1.0.CR1
+ Version: 2.1.0.GA
</diffmk:wrapper></releaseinfo>
<abstract>
<title></title>
14 years, 10 months
JBoss Tools SVN: r20645 - branches/jbosstools-3.1.x/as/docs/reference.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 07:35:08 -0500 (Thu, 04 Mar 2010)
New Revision: 20645
Modified:
branches/jbosstools-3.1.x/as/docs/reference/pom.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Modified: branches/jbosstools-3.1.x/as/docs/reference/pom.xml
===================================================================
--- branches/jbosstools-3.1.x/as/docs/reference/pom.xml 2010-03-04 11:43:11 UTC (rev 20644)
+++ branches/jbosstools-3.1.x/as/docs/reference/pom.xml 2010-03-04 12:35:08 UTC (rev 20645)
@@ -32,7 +32,7 @@
<profile>
<id>releaseJBDS</id>
<properties>
- <master>master_output.xml</master>
+ <master>master.xml</master>
<xsl-single>classpath:/xslt/com/jboss/tools/xhtml-single-release.xsl</xsl-single>
<xsl-chunked>classpath:/xslt/com/jboss/tools/xhtml-release.xsl</xsl-chunked>
<xsl-pdf>classpath:/xslt/com/jboss/tools/pdf.xsl</xsl-pdf>
14 years, 10 months
JBoss Tools SVN: r20644 - in branches/jbosstools-3.1.x/drools/docs/reference: en and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 06:43:11 -0500 (Thu, 04 Mar 2010)
New Revision: 20644
Modified:
branches/jbosstools-3.1.x/drools/docs/reference/en/master_output.xml
branches/jbosstools-3.1.x/drools/docs/reference/pom.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Modified: branches/jbosstools-3.1.x/drools/docs/reference/en/master_output.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/reference/en/master_output.xml 2010-03-04 11:32:52 UTC (rev 20643)
+++ branches/jbosstools-3.1.x/drools/docs/reference/en/master_output.xml 2010-03-04 11:43:11 UTC (rev 20644)
@@ -21,761 +21,1107 @@
<!ENTITY strutsreflink "../../struts_tools_ref_guide/html_single/index.html">
<!ENTITY strutstutoriallink "../../struts_tools_tutorial/html_single/index.html">
-]><book xmlns:diffmk="http://diffmk.sf.net/ns/diff">
-
- <bookinfo>
- <title>Drools Tools Reference Guide</title>
- <corpauthor>
- <inlinemediaobject>
- <imageobject role="fo">
- <imagedata fileref="images/jbosstools_logo.png" format="PNG"></imagedata>
- </imageobject>
- <imageobject role="html">
- <imagedata></imagedata>
- </imageobject>
- </inlinemediaobject>
- </corpauthor>
- <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
-
- <pubdate>April 2008</pubdate>
- <copyright>
- <year>2007</year>
- <year>2009</year>
- <holder>JBoss by Red Hat</holder>
- </copyright>
- <releaseinfo>
- Version: 5.1.0.trunk
- </releaseinfo>
-<abstract>
- <title></title>
- <para>
- <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/as/pdf/AS_Reference_...">PDF version</ulink>
- </para>
-</abstract>
-
- </bookinfo>
-
-
- <toc></toc>
-
-<chapter id="introduction" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/drools/docs/reference/en/modules/introduction.xml" xreflabel="introduction">
- <title>Introduction</title>
-
- <section id="whatisDrools">
- <title>What is Drools?</title>
-
- <para><property moreinfo="none">Drools</property> is a business rule management system (BRMS) with a forward
- chaining inference based rules engine, more correctly known as a production rule system,
- using an enhanced implementation of the Rete algorithm.</para>
-
- <para> In this guide we are going to get you familiar with Drools Eclipse plugin which
- provides development tools for creating, executing and debugging Drools processes and
- rules from within Eclipse.</para>
-
- <note>
- <title>Note:</title>
- <para>It is assumed that you has some familiarity with rule engines and Drools in
- particular. If no, we suggest that you look carefully through the <ulink url="http://downloads.jboss.com/drools/docs/4.0.7.19894.GA/html_single/index.html">Drools Documentation</ulink>.</para>
- </note>
-
- <para><property moreinfo="none">Drools Tools</property> come bundled with <property moreinfo="none">JBoss Tools</property>
- set of Eclipse plugins. How to install <property moreinfo="none">JBoss Tools</property> you can find in
- the <ulink url="../../GettingStartedGuide/html_single/index.html#JBossToolsInstall">Getting Started Guide</ulink>.</para>
- </section>
-
- <section id="drools_key_features">
- <title>Drools Tools Key Features</title>
-
- <para>The following table lists all valuable features of the <property moreinfo="none">Drools
- Tools</property>.</para>
- <table>
- <title>Key Functionality of Drools Tools</title>
- <tgroup cols="3">
-
- <colspec align="left" colnum="1" colwidth="1*"></colspec>
- <colspec colnum="2" colwidth="5*"></colspec>
- <colspec align="left" colnum="3" colwidth="1*"></colspec>
-
- <thead>
- <row>
- <entry>Feature</entry>
- <entry>Benefit</entry>
- <entry>Chapter</entry>
- </row>
- </thead>
-
- <tbody>
-
- <row>
- <entry>
- <para>Wizard for creating a new Drools Project</para>
- </entry>
- <entry>
- <para>The wizard allows to create a sample project to easy get started
- with Drools</para>
- </entry>
- <entry>
- <link linkend="sample_drools_project">Creating a Sample Drools
- Project</link>
- </entry>
- </row>
-
- <row>
- <entry>
- <para>Wizards for creation new Drools resources</para>
- </entry>
- <entry>
- <para>A set of wizards are provided with the Drools Eclipse tools to
- quickly create a new Rule resource, a new Domain Specific language,
- Decision Table and Business rule</para>
- </entry>
- <entry>
- <link linkend="creating_rule">Creating a New Rule</link>
- <!--link linkend="creating_dsl">Creating a New DSL</link>
- <link linkend="creating_decision_table">Creating a New Decision
- Table</link>
- <link linkend="creating_business_rule">Creating a New Business
- Rule</link-->
- </entry>
- </row>
-
- <row>
- <entry>
- <para>The Rule editor</para>
- </entry>
- <entry>
- <para>An editor that is aware of DRL syntax and provides content
- assistance and synchronizing with the Outline view</para>
- </entry>
- <entry>
- <link linkend="textual_rule_editor">The Rule Editor</link>
- </entry>
- </row>
-
- <row>
- <entry>
- <para>The Domain Specific Language editor</para>
- </entry>
- <entry>
- <para>The editor allows to create and manage mappings from users
- language to the rule language</para>
- </entry>
- <entry>
- <!--link linkend="dsl_editor">The Domain Specific Language Editor</link-->
- </entry>
- </row>
-
- <row>
- <entry>
- <para>The Guided editor</para>
- </entry>
- <entry>
- <para>This guided editor for rules allows you to build rules in a GUI
- driven fashion based on your object model</para>
- </entry>
- <entry>
- <!--link linkend="guided_editor">The Guided Editor</link-->
- </entry>
- </row>
-
- <row>
- <entry>
- <para>The Rule Flow graphical editor</para>
- </entry>
- <entry>
- <para>The editor is meant for editing visual graphs which represent a
- process (a rule flow)</para>
- </entry>
- <entry>
- <!--link linkend="ruleflow_editor">The Rule Flow Graphical Editor</link-->
- </entry>
- </row>
-
- </tbody>
- </tgroup>
- </table>
- </section>
-
- <section>
- <title>Other relevant resources on the topic</title>
-
- <itemizedlist>
- <listitem>
- <para>Drools on <ulink url="http://www.jboss.org/drools/">JBoss.org</ulink></para>
- </listitem>
-
- <listitem>
- <para>
- <ulink url="http://www.jboss.org/tools/">JBoss Tools Home Page</ulink>
- </para>
- </listitem>
-
- <listitem>
- <para>
- <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">The latest
- JBossTools/JBDS documentation builds</ulink>
- </para>
- </listitem>
-
- <listitem>
- <para>All <property moreinfo="none">JBoss Tools/JBDS</property> documentation you can find on the
- <ulink url="http://docs.jboss.org/tools/">documentation release
- page</ulink>.</para>
- </listitem>
- </itemizedlist>
-
- </section>
-</chapter>
-
-
-<chapter id="create_new_project" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/drools/docs/reference/en/modules/create_new_project.xml" xreflabel="create_new_project">
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Drools Tools</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Creating a New Drools Project</title>
-
- <para>In this chapter we are going to show you how to setup an executable sample Drools project
- to start using rules immediately.</para>
-
-
-
- <section id="sample_drools_project">
- <title>Creating a Sample Drools Project</title>
-
- <para>First, we suggest that you use <property moreinfo="none">Drools perspective</property> which is aimed
- at work with Drools specific resources.</para>
-
- <para>To create a new Drools project follow to <emphasis>
- <property moreinfo="none">File > New > Drools Project</property>. </emphasis> This will open
- <property moreinfo="none">New Drools Project wizard</property> like on the figure below.</para>
-
- <para>On the first page type the project name and click
- <emphasis><property moreinfo="none">Next</property>.</emphasis></para>
-
- <figure float="0">
- <title>Creating a New Drools Project</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project1.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Next you have a choice to add some default artifacts to it like sample rules, decision
- tables or ruleflows and Java classes for them. Let's select first two check
- boxes and press <emphasis>
- <property moreinfo="none">Next</property>. </emphasis></para>
-
- <figure float="0">
- <title>Selecting Drools Project Elements</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project2.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Next page asks you to specify a Drools runtime. If you have not yet set it up, you
- should do this now by clicking the <emphasis>
- <property moreinfo="none">Configure Workspace Settings</property>
- </emphasis> link.</para>
-
- <figure float="0">
- <title>Configuring Drools Runtime</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project3.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>You should see the <property moreinfo="none">Preferences window</property> where you can configure the
- workspace settings for Drools runtimes. To create a new runtime, press the <emphasis>
- <property moreinfo="none">Add</property>
- </emphasis> button. The appeared dialog prompts you to enter a
- name for a new runtime and a path to the Drools runtime on your file system.</para>
-
- <note>
- <title>Note:</title>
- <para>A Drools runtime is a collection of jars on your file system that represent one
- specific release of the Drools project jars. While creating a new runtime, you must
- either point to the release of your choice, or you can simply create a new runtime
- on your file system from the jars included in the Drools Eclipse plugin.</para>
- </note>
-
- <figure float="0">
- <title>Adding a New Drools Runtime</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project4.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Let's simply create a new Drools 5 runtime from the jars embedded in the
- Drools Eclipse plugin. Thus, you should press <emphasis>
- <property moreinfo="none">Create a new Drools 5 runtime</property>
- </emphasis> button and select the folder where you want this runtime to be created and
- hit <emphasis>
- <property moreinfo="none">OK</property>.</emphasis></para>
-
- <para>You will see the newly created runtime show up in your list of Drools runtimes. Check
- it and press <emphasis>
- <property moreinfo="none">OK</property>.</emphasis></para>
-
- <figure float="0">
- <title>Selecting a Drools Runtime</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project5.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Now press <emphasis>
- <property moreinfo="none">Finish</property>
- </emphasis> to complete the project creation.</para>
-
- <figure float="0">
- <title>Completing the Drools Project Creation</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project6.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>This will setup a basic structure, classpath and sample rules and test case to get you
- started.</para>
- </section>
-
-
- <section id="structure_overview">
- <title>Drools Project Structure Overview</title>
-
- <para>Now let's look at the structure of the organized project. In the
- <property moreinfo="none">Package Explorer</property> you should see the following:</para>
-
- <figure float="0">
- <title>Drools Project in the Package Explorer</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project7.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>The newly created project contains an example rule file <emphasis>
- <property moreinfo="none">Sample.drl</property>
- </emphasis> in the <emphasis>
- <property moreinfo="none">src/main/rules</property>
- </emphasis> directory and an example java file <emphasis>
- <property moreinfo="none">DroolsTest.java</property>
- </emphasis> that can be used to execute the rules in a Drools engine in the folder <emphasis>
- <property moreinfo="none">src/main/java</property>
- </emphasis>, in the <emphasis>
- <property moreinfo="none">com.sample</property>
- </emphasis> package. All the others jar's that are necessary during execution
- are also added to the classpath in a custom classpath container called <property moreinfo="none">Drools
- Library</property>.</para>
-
- <tip>
- <title>Tip:</title>
- <para>Rules do not have to be kept in Java projects at all, this is just a convenience
- for people who are already using eclipse as their Java IDE.</para>
- </tip>
-
- </section>
-
- <section id="creating_rule">
- <title>Creating a New Rule</title>
-
- <para>Now we are going to add a new Rule resource to the project.</para>
-
- <para>You can either create an empty text <emphasis>
- <property moreinfo="none">.drl</property>
- </emphasis> file or make use of the special <property moreinfo="none">New Rule Resource
- wizard</property> to do it.</para>
-
- <para>To open the wizard follow to <emphasis>
- <property moreinfo="none">File > New > Rule Resource</property>
- </emphasis> or use the menu with the JBoss Drools icon on the toolbar.</para>
-
- <figure float="0">
- <title>Opening the New Rule Resource Wizard</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project8.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>On the wizard page first select <emphasis>
- <property moreinfo="none">/rules</property>
- </emphasis> as a top level directory to store your rules and type the rule name. Next
- it's mandatory to specify the rule package name. It defines a namespace that
- groups rules together.</para>
-
- <figure float="0">
- <title>New Rule Resource Wizard</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project9.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>As a result the wizard generates a rule skeleton to get you started.</para>
-
- <figure float="0">
- <title>New Rule</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/create_new_project/create_new_project10.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- </section>
-
-</chapter>
-
-
-<chapter id="debugging_rules" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/drools/docs/reference/en/modules/debugging_rules.xml" xreflabel="debugging_rules">
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Drools Tools</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Debugging rules</title>
-
- <para>This chapter describes how to debug rules during the execution of your Drools application.</para>
-
- <section id="creating_breakpoints">
- <title>Creating Breakpoints</title>
-
- <para>At first, we'll focus on how to add
- breakpoints in the consequences of your rules.</para>
-
- <para>Whenever such a breakpoint is uncounted
- during the execution of the rules, the execution is halted. It's possible then inspect the
- variables known at that point and use any of the default debugging actions to decide what
- should happen next (step over, continue, etc). To inspect
- the content of the working memory and agenda the Debug views can be used.</para>
-
- <para>You can add/remove rule breakpoints in <emphasis>
- <property moreinfo="none">.drl</property>
- </emphasis> files in two ways, similar to adding breakpoints to Java files:</para>
-
- <itemizedlist>
- <listitem>
- <para>Double-click the ruler in the <property moreinfo="none">Rule editor</property> at the line
- where you want to add a breakpoint.</para>
- <tip>
- <title>Tip:</title>
- <para>Note that rule breakpoints can only be created in the consequence of a
- rule. Double-clicking on a line where no breakpoint is allowed will do
- nothing.</para>
- </tip>
- <para>A breakpoint can be removed by double-clicking the ruler once more. </para>
- </listitem>
-
- <listitem>
- <para>Right-click the ruler. Select <emphasis>
- <property moreinfo="none">Toggle Breakpoint</property>
- </emphasis> action in the appeared popup menu. Clicking the action will add a
- breakpoint at the selected line or remove it if there is one already.</para>
- </listitem>
- </itemizedlist>
-
- <figure float="0">
- <title>Adding Breakpoints</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/debugging_rules/debugging_rules1.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>The <property moreinfo="none">Debug perspective</property> contains a <property moreinfo="none">Breakpoints
- view</property> which can be used to see all defined breakpoints, get their
- properties, enable/disable or remove them, etc. You can switch to it by navigating to <emphasis>
- <property moreinfo="none">Window > Perspective > Others > Debug</property>.</emphasis></para>
- </section>
-
- <section id="debugging">
- <title>Debugging</title>
-
- <para>Drools breakpoints are only enabled if you debug your application as a Drools
- Application. To do this you should perform one of the actions:</para>
-
- <itemizedlist>
- <listitem>
- <para>Select the main class of your application. Right click it and select <emphasis>
- <property moreinfo="none">Debug As > Drools Application</property>.</emphasis></para>
- </listitem>
- </itemizedlist>
- <figure float="0">
- <title>Debugging Drools Application</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/debugging_rules/debugging_rules2.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <itemizedlist>
- <listitem>
- <para>Alternatively, you can also go to <emphasis>
- <property moreinfo="none">Debug As > Debug Configuration</property>
- </emphasis> to open a new dialog for creating, managing and running debug
- configurations.</para>
-
- <para>Select the <emphasis>
- <property moreinfo="none">Drools Application</property>
- </emphasis> item in the left tree and click the <emphasis>
- <property moreinfo="none">New launch configuration</property>
- </emphasis> button (leftmost icon in the toolbar above the tree). This will
- create a new configuration and already fill in some of the properties (like the
- Project and Main class) based on main class you selected in the beginning. All
- properties shown here are the same as any standard Java program.</para>
- </listitem>
- </itemizedlist>
-
- <figure float="0">
- <title>New Debug Configuration</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/debugging_rules/debugging_rules3.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <tip>
- <title>Tip:</title>
- <para>Remember to change the name of your debug configuration to something meaningful.</para>
- </tip>
-
- <para>Next
- click the <emphasis>
- <property moreinfo="none">Debug</property>
- </emphasis> button on the bottom to start debugging your application. </para>
-
- <para>After enabling the debugging, the application starts executing and will halt if
- any breakpoint is encountered. This can be a Drools rule breakpoint, or any other
- standard Java breakpoint. Whenever a Drools rule breakpoint is encountered, the
- corresponding <emphasis>
- <property moreinfo="none">.drl</property></emphasis> file is opened and the active line is highlighted. The Variables view
- also contains all rule parameters and their value. You can then use the default Java
- debug actions to decide what to do next (resume, terminate, step over, etc.). The debug
- views can also be used to determine the contents of the working memory and agenda at
- that time as well (you don't have to select a working memory now, the current executing
- working memory is automatically shown).</para>
-
-
- </section>
-</chapter>
-
-
-<chapter id="editors" xml:base="file:///home/ochikvina/WORK/for_compare/jbosstools-3.1.0.CR1/drools/docs/reference/en/modules/editors.xml" xreflabel="editors">
- <chapterinfo>
- <keywordset>
- <keyword>JBoss Tools</keyword>
- <keyword>Drools Tools</keyword>
- </keywordset>
- </chapterinfo>
-
- <title>Editors</title>
-
- <section id="textual_rule_editor">
- <title>The Rule Editor</title>
-
- <para>The <property moreinfo="none">Rule editor</property> works on files that have a <emphasis>
- <property moreinfo="none">.drl</property>
- </emphasis> (or <emphasis>
- <property moreinfo="none">.rule</property>
- </emphasis> in the case of spreading rules across multiple rule files) extension.</para>
-
- <figure float="0">
- <title>New Rule</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors1.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>The editor follows the pattern of a normal text editor in eclipse, with all the normal
- features of a text editor:</para>
-
- <itemizedlist>
- <listitem>
- <para>
- <link linkend="rules_editor_content_assist">Content Assist</link>
- </para>
- </listitem>
-
- <listitem>
- <para>
- <link linkend="rules_editor_code_folding">Code Folding</link>
- </para>
- </listitem>
-
- <!-- <listitem>
- <para>
- <link linkend="rules_editor_error_reporting">Error Reporting</link>
- </para>
- </listitem>-->
-
- <listitem>
- <para>
- <link linkend="rules_editor_sync_with_outline">Synchronization with Outline
- View</link>
- </para>
- </listitem>
- </itemizedlist>
-
- <section id="rules_editor_content_assist">
- <title>Content Assist</title>
-
- <para>While working in the <property moreinfo="none">Rule editor</property> you can get a content
- assistance the usual way by pressing <emphasis>
- <property moreinfo="none">Ctrl + Space</property>.</emphasis></para>
-
- <para>Content Assist shows all possible keywords for the current cursor position.</para>
-
- <figure float="0">
- <title>Content Assist Demonstration</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors2.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Content Assist inside of the <emphasis>
- <property moreinfo="none">Message</property>
- </emphasis> suggests all available fields.</para>
-
- <figure float="0">
- <title>Content Assist Demonstration</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors3.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- </section>
-
- <section id="rules_editor_code_folding">
- <title>Code Folding</title>
-
- <para>Code folding is also available in the <property moreinfo="none">Rule editor</property>. To
- hide/show sections of the file use the icons with minus/plus on the left vertical
- line of the editor.</para>
-
- <figure float="0">
- <title>Code Folding</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors4.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- </section>
-
- <!--section id="rules_editor_error_reporting">
- <title>Error Reporting</title>
-
- </section-->
-
- <section id="rules_editor_sync_with_outline">
- <title>Synchronization with Outline View</title>
-
- <para>The <property moreinfo="none">Rule editor</property> works in synchronization with the
- <property moreinfo="none">Outline view</property> which shows the structure of the rules,
- imports in the file and also globals and functions if the file has them.</para>
-
- <figure float="0">
- <title>Synchronization with Outline View</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors5.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>The view is updated on save. It provides a quick way of navigating around rules by
- names in a file which may have hundreds of rules. The items are sorted
- alphabetically by default.</para>
- </section>
-
- <section id="rete_view">
- <title>The Rete Tree View</title>
-
- <para>The <property moreinfo="none">Rete Tree view</property> shows you the current Rete Network for
- your <emphasis>
- <property moreinfo="none">.drl</property>
- </emphasis> file. Just click on the <emphasis>
- <property moreinfo="none">Rete Tree tab</property>
- </emphasis> at the bottom of the <property moreinfo="none">Rule editor</property>.</para>
-
- <figure float="0">
- <title>Rete Tree</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors6.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>Afterwards you can generate the current Rete Network visualization. You can push
- and pull the nodes to arrange your optimal network overview.</para>
- <para>If you got hundreds of nodes, select some of them with a frame. Then you can pull
- groups of them.</para>
-
- <figure float="0">
- <title>Selecting the nodes in the Rete Tree with Frame</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors7.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <para>You can zoom in and out the Rete tree in case not all nodes are shown in the
- current view. For this use the combo box or "+" and "-" icons on the toolbar.</para>
-
- <figure float="0">
- <title>Rete Tree Zooming</title>
- <mediaobject>
- <imageobject>
- <imagedata fileref="images/editors/editors8.png"></imagedata>
- </imageobject>
- </mediaobject>
- </figure>
-
- <note>
- <title>Note:</title>
-
- <para>The <property moreinfo="none">Rete Tree view</property> works only in Drools Rule Projects,
- where the Drools Builder is set in the project properties.</para>
- </note>
- <para>We hope, this guide helped you to get started with the JBoss BPMN Convert module. Besides, for additional information you are welcome on <ulink url="http://www.jboss.com/index.html?module=bb&op=viewforum&f=201">JBoss forum</ulink>.</para>
- </section>
-
- </section>
-
-</chapter>
-
-
-
-</book>
+]><book xmlns:diffmk="http://diffmk.sf.net/ns/diff">
+
+ <bookinfo>
+ <title>Drools Tools Reference Guide</title>
+ <corpauthor>
+ <inlinemediaobject>
+ <imageobject role="fo">
+ <imagedata fileref="images/jbosstools_logo.png" format="PNG"></imagedata>
+ </imageobject>
+ <imageobject role="html">
+ <imagedata></imagedata>
+ </imageobject>
+ </inlinemediaobject>
+ </corpauthor>
+ <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
+
+ <copyright>
+ <year>2007</year>
+ <year>2008</year>
+ <year>2009</year>
+ <year>2010</year>
+ <holder>JBoss by Red Hat</holder>
+ </copyright>
+ <releaseinfo>
+ Version: 5.1.0.trunk
+ </releaseinfo>
+<abstract>
+ <title></title>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/as/pdf/AS_Reference_...">PDF version</ulink>
+ </para>
+</abstract>
+
+ </bookinfo>
+
+
+ <toc></toc>
+
+<chapter id="introduction" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/reference/en/modules/introduction.xml" xreflabel="introduction">
+ <title>Introduction</title>
+
+ <section id="whatisDrools">
+ <title>What is Drools?</title>
+
+ <para><property moreinfo="none">Drools</property> is a business rule management system (BRMS) with a forward
+ chaining inference based rules engine, more correctly known as a production rule system,
+ using an enhanced implementation of the Rete algorithm.</para>
+
+ <para> In this guide we are going to get you familiar with Drools Eclipse plugin which
+ provides development tools for creating, executing and debugging Drools processes and
+ rules from within Eclipse.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>It is assumed that you has some familiarity with rule engines and Drools in
+ particular. If no, we suggest that you look carefully through the <ulink url="http://downloads.jboss.com/drools/docs/4.0.7.19894.GA/html_single/index.html">Drools Documentation</ulink>.</para>
+ </note>
+
+ <para><property moreinfo="none">Drools Tools</property> come bundled with <property moreinfo="none">JBoss Tools</property>
+ set of Eclipse plugins. How to install <property moreinfo="none">JBoss Tools</property> you can find in
+ the <ulink url="../../GettingStartedGuide/html_single/index.html#JBossToolsInstall">Getting Started Guide</ulink>.</para>
+ </section>
+
+ <section id="drools_key_features">
+ <title>Drools Tools Key Features</title>
+
+ <para>The following table lists all valuable features of the <property moreinfo="none">Drools
+ Tools</property>.</para>
+ <table>
+ <title>Key Functionality of Drools Tools</title>
+ <tgroup cols="3">
+
+ <colspec align="left" colnum="1" colwidth="1*"></colspec>
+ <colspec colnum="2" colwidth="5*"></colspec>
+ <colspec align="left" colnum="3" colwidth="1*"></colspec>
+
+ <thead>
+ <row>
+ <entry>Feature</entry>
+ <entry>Benefit</entry>
+ <entry>Chapter</entry>
+ </row>
+ </thead>
+
+ <tbody>
+
+ <row>
+ <entry>
+ <para>Wizard for creating a new Drools Project</para>
+ </entry>
+ <entry>
+ <para>The wizard allows to create a sample project to easy get started
+ with Drools</para>
+ </entry>
+ <entry>
+ <link linkend="sample_drools_project">Creating a Sample Drools
+ Project</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Wizards for creation new Drools resources</para>
+ </entry>
+ <entry>
+ <para>A set of wizards are provided with the Drools Eclipse tools to
+ quickly create a new Rule resource, a new Domain Specific language,
+ Decision Table and Business rule</para>
+ </entry>
+ <entry>
+ <link linkend="creating_rule">Creating a New Rule</link>
+ <!--link linkend="creating_dsl">Creating a New DSL</link>
+ <link linkend="creating_decision_table">Creating a New Decision
+ Table</link>
+ <link linkend="creating_business_rule">Creating a New Business
+ Rule</link-->
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>The Rule editor</para>
+ </entry>
+ <entry>
+ <para>An editor that is aware of DRL syntax and provides content
+ assistance and synchronizing with the Outline view</para>
+ </entry>
+ <entry>
+ <link linkend="textual_rule_editor">The Rule Editor</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>The Domain Specific Language editor</para>
+ </entry>
+ <entry>
+ <para>The editor allows to create and manage mappings from users
+ language to the rule language</para>
+ </entry>
+ <entry>
+ <link linkend="dsl_editor">The Domain Specific Language Editor</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>The Guided editor</para>
+ </entry>
+ <entry>
+ <para>This guided editor for rules allows you to build rules in a GUI
+ driven fashion based on your object model</para>
+ </entry>
+ <entry>
+ <!--link linkend="guided_editor">The Guided Editor</link-->
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>The Rule Flow graphical editor</para>
+ </entry>
+ <entry>
+ <para>The editor is meant for editing visual graphs which represent a
+ process (a rule flow)</para>
+ </entry>
+ <entry>
+ <link linkend="ruleflow_editor">The Rule Flow Graphical Editor</link>
+ </entry>
+ </row>
+
+ </tbody>
+ </tgroup>
+ </table>
+ </section>
+
+ <section>
+ <title>Other relevant resources on the topic</title>
+
+ <itemizedlist>
+ <listitem>
+ <para>Drools on <ulink url="http://www.jboss.org/drools/">JBoss.org</ulink></para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://www.jboss.org/tools/">JBoss Tools Home Page</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">The latest
+ JBossTools/JBDS documentation builds</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>All <property moreinfo="none">JBoss Tools/JBDS</property> documentation you can find on the
+ <ulink url="http://docs.jboss.org/tools/">documentation release
+ page</ulink>.</para>
+ </listitem>
+ </itemizedlist>
+
+ </section>
+</chapter>
+
+
+<chapter id="create_new_project" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/reference/en/modules/create_new_project.xml" xreflabel="create_new_project">
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Drools Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Creating a New Drools Project</title>
+
+ <para>In this chapter we are going to show you how to setup an executable sample Drools project
+ to start using rules immediately.</para>
+
+
+
+ <section id="sample_drools_project">
+ <title>Creating a Sample Drools Project</title>
+
+ <para>First, we suggest that you use <property moreinfo="none">Drools perspective</property> which is aimed
+ at work with Drools specific resources.</para>
+
+ <para>To create a new Drools project follow to <emphasis>
+ <property moreinfo="none">File > New > Drools Project</property>. </emphasis> This will open
+ <property moreinfo="none">New Drools Project wizard</property> like on the figure below.</para>
+
+ <para>On the first page type the project name and click
+ <emphasis><property moreinfo="none">Next</property>.</emphasis></para>
+
+ <figure float="0">
+ <title>Creating a New Drools Project</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project1.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Next you have a choice to add some default artifacts to it like sample rules, decision
+ tables or ruleflows and Java classes for them. Let's select first two check
+ boxes and press <emphasis>
+ <property moreinfo="none">Next</property>. </emphasis></para>
+
+ <figure float="0">
+ <title>Selecting Drools Project Elements</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Next page asks you to specify a Drools runtime. If you have not yet set it up, you
+ should do this now by clicking the <emphasis>
+ <property moreinfo="none">Configure Workspace Settings</property>
+ </emphasis> link.</para>
+
+ <figure float="0">
+ <title>Configuring Drools Runtime</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>You should see the <property moreinfo="none">Preferences window</property> where you can configure the
+ workspace settings for Drools runtimes. To create a new runtime, press the <emphasis>
+ <property moreinfo="none">Add</property>
+ </emphasis> button. The appeared dialog prompts you to enter a
+ name for a new runtime and a path to the Drools runtime on your file system.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>A Drools runtime is a collection of jars on your file system that represent one
+ specific release of the Drools project jars. While creating a new runtime, you must
+ either point to the release of your choice, or you can simply create a new runtime
+ on your file system from the jars included in the Drools Eclipse plugin.</para>
+ </note>
+
+ <figure float="0">
+ <title>Adding a New Drools Runtime</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project4.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Let's simply create a new Drools 5 runtime from the jars embedded in the
+ Drools Eclipse plugin. Thus, you should press <emphasis>
+ <property moreinfo="none">Create a new Drools 5 runtime</property>
+ </emphasis> button and select the folder where you want this runtime to be created and
+ hit <emphasis>
+ <property moreinfo="none">OK</property>.</emphasis></para>
+
+ <para>You will see the newly created runtime show up in your list of Drools runtimes. Check
+ it and press <emphasis>
+ <property moreinfo="none">OK</property>.</emphasis></para>
+
+ <figure float="0">
+ <title>Selecting a Drools Runtime</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project5.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Now press <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis> to complete the project creation.</para>
+
+ <figure float="0">
+ <title>Completing the Drools Project Creation</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project6.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>This will setup a basic structure, classpath and sample rules and test case to get you
+ started.</para>
+ </section>
+
+
+ <section id="structure_overview">
+ <title>Drools Project Structure Overview</title>
+
+ <para>Now let's look at the structure of the organized project. In the
+ <property moreinfo="none">Package Explorer</property> you should see the following:</para>
+
+ <figure float="0">
+ <title>Drools Project in the Package Explorer</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project7.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The newly created project contains an example rule file <emphasis>
+ <property moreinfo="none">Sample.drl</property>
+ </emphasis> in the <emphasis>
+ <property moreinfo="none">src/main/rules</property>
+ </emphasis> directory and an example java file <emphasis>
+ <property moreinfo="none">DroolsTest.java</property>
+ </emphasis> that can be used to execute the rules in a Drools engine in the folder <emphasis>
+ <property moreinfo="none">src/main/java</property>
+ </emphasis>, in the <emphasis>
+ <property moreinfo="none">com.sample</property>
+ </emphasis> package. All the others jar's that are necessary during execution
+ are also added to the classpath in a custom classpath container called <property moreinfo="none">Drools
+ Library</property>.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para>Rules do not have to be kept in Java projects at all, this is just a convenience
+ for people who are already using eclipse as their Java IDE.</para>
+ </tip>
+
+ </section>
+
+ <section id="creating_rule">
+ <title>Creating a New Rule</title>
+
+ <para>Now we are going to add a new Rule resource to the project.</para>
+
+ <para>You can either create an empty text <emphasis>
+ <property moreinfo="none">.drl</property>
+ </emphasis> file or make use of the special <property moreinfo="none">New Rule Resource
+ wizard</property> to do it.</para>
+
+ <para>To open the wizard follow to <emphasis>
+ <property moreinfo="none">File > New > Rule Resource</property>
+ </emphasis> or use the menu with the JBoss Drools icon on the toolbar.</para>
+
+ <figure float="0">
+ <title>Opening the New Rule Resource Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project8.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>On the wizard page first select <emphasis>
+ <property moreinfo="none">/rules</property>
+ </emphasis> as a top level directory to store your rules and type the rule name. Next
+ it's mandatory to specify the rule package name. It defines a namespace that
+ groups rules together.</para>
+
+ <figure float="0">
+ <title>New Rule Resource Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project9.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>As a result the wizard generates a rule skeleton to get you started.</para>
+
+ <figure float="0">
+ <title>New Rule</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/create_new_project/create_new_project10.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ </section>
+
+</chapter>
+
+
+<chapter id="debugging_rules" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/reference/en/modules/debugging_rules.xml" xreflabel="debugging_rules">
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Drools Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Debugging rules</title>
+
+ <para>This chapter describes how to debug rules during the execution of your Drools application.</para>
+
+ <section id="creating_breakpoints">
+ <title>Creating Breakpoints</title>
+
+ <para>At first, we'll focus on how to add
+ breakpoints in the consequences of your rules.</para>
+
+ <para>Whenever such a breakpoint is uncounted
+ during the execution of the rules, the execution is halted. It's possible then inspect the
+ variables known at that point and use any of the default debugging actions to decide what
+ should happen next (step over, continue, etc). To inspect
+ the content of the working memory and agenda the Debug views can be used.</para>
+
+ <para>You can add/remove rule breakpoints in <emphasis>
+ <property moreinfo="none">.drl</property>
+ </emphasis> files in two ways, similar to adding breakpoints to Java files:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>Double-click the ruler in the <property moreinfo="none">Rule editor</property> at the line
+ where you want to add a breakpoint.</para>
+ <tip>
+ <title>Tip:</title>
+ <para>Note that rule breakpoints can only be created in the consequence of a
+ rule. Double-clicking on a line where no breakpoint is allowed will do
+ nothing.</para>
+ </tip>
+ <para>A breakpoint can be removed by double-clicking the ruler once more. </para>
+ </listitem>
+
+ <listitem>
+ <para>Right-click the ruler. Select <emphasis>
+ <property moreinfo="none">Toggle Breakpoint</property>
+ </emphasis> action in the appeared popup menu. Clicking the action will add a
+ breakpoint at the selected line or remove it if there is one already.</para>
+ </listitem>
+ </itemizedlist>
+
+ <figure float="0">
+ <title>Adding Breakpoints</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/debugging_rules/debugging_rules1.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The <property moreinfo="none">Debug perspective</property> contains a <property moreinfo="none">Breakpoints
+ view</property> which can be used to see all defined breakpoints, get their
+ properties, enable/disable or remove them, etc. You can switch to it by navigating to <emphasis>
+ <property moreinfo="none">Window > Perspective > Others > Debug</property>.</emphasis></para>
+ </section>
+
+ <section id="debugging">
+ <title>Debugging</title>
+
+ <para>Drools breakpoints are only enabled if you debug your application as a Drools
+ Application. To do this you should perform one of the actions:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>Select the main class of your application. Right click it and select <emphasis>
+ <property moreinfo="none">Debug As > Drools Application</property>.</emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <figure float="0">
+ <title>Debugging Drools Application</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/debugging_rules/debugging_rules2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <itemizedlist>
+ <listitem>
+ <para>Alternatively, you can also go to <emphasis>
+ <property moreinfo="none">Debug As > Debug Configuration</property>
+ </emphasis> to open a new dialog for creating, managing and running debug
+ configurations.</para>
+
+ <para>Select the <emphasis>
+ <property moreinfo="none">Drools Application</property>
+ </emphasis> item in the left tree and click the <emphasis>
+ <property moreinfo="none">New launch configuration</property>
+ </emphasis> button (leftmost icon in the toolbar above the tree). This will
+ create a new configuration and already fill in some of the properties (like the
+ Project and Main class) based on main class you selected in the beginning. All
+ properties shown here are the same as any standard Java program.</para>
+ </listitem>
+ </itemizedlist>
+
+ <figure float="0">
+ <title>New Debug Configuration</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/debugging_rules/debugging_rules3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <tip>
+ <title>Tip:</title>
+ <para>Remember to change the name of your debug configuration to something meaningful.</para>
+ </tip>
+
+ <para>Next
+ click the <emphasis>
+ <property moreinfo="none">Debug</property>
+ </emphasis> button on the bottom to start debugging your application. </para>
+
+ <para>After enabling the debugging, the application starts executing and will halt if
+ any breakpoint is encountered. This can be a Drools rule breakpoint, or any other
+ standard Java breakpoint. Whenever a Drools rule breakpoint is encountered, the
+ corresponding <emphasis>
+ <property moreinfo="none">.drl</property></emphasis> file is opened and the active line is highlighted. The Variables view
+ also contains all rule parameters and their value. You can then use the default Java
+ debug actions to decide what to do next (resume, terminate, step over, etc.). The debug
+ views can also be used to determine the contents of the working memory and agenda at
+ that time as well (you don't have to select a working memory now, the current executing
+ working memory is automatically shown).</para>
+
+
+ </section>
+</chapter>
+
+
+<chapter id="editors" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/reference/en/modules/editors.xml" xreflabel="editors">
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Drools Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Editors</title>
+ <section id="dsl_editor">
+ <title>DSL Editor</title>
+ <para>A domain-specific language is a set of custom rules,
+ that is created specifically to solve problems in a particular domain
+ and is not intended to be able to solve problems outside it.
+ A DSL's configuration is stored in plain text.
+ </para>
+ <para>In Drools this configuration is presented by <property moreinfo="none">.dsl</property>
+ files that can be created by <emphasis>right click on the project->New->Other->Drools->Domain Specific Language</emphasis>.</para>
+ <para>DSL Editor is a default editor for <property moreinfo="none">.dsl</property> files:</para>
+ <figure float="0">
+ <title>DSL Editor</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1a.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>In the table below all the components of the DSL Editor page are described:</para>
+ <table>
+ <title>DSL Editor Components.</title>
+ <tgroup cols="2">
+ <colspec align="left" colnum="1" colwidth="1*"></colspec>
+ <colspec align="left" colnum="2" colwidth="3*"></colspec>
+
+ <thead>
+ <row>
+ <entry>Components</entry>
+ <entry>Description</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>Description</entry>
+ <entry>User's comments on a certain language message mapping</entry>
+ </row>
+ <row>
+ <entry>Table of language message mappings</entry>
+ <entry>The table is divided into 4 rows:
+ <itemizedlist id="rows">
+ <listitem><para><emphasis>Language Expression</emphasis> :expression you want to use as a rule</para></listitem>
+ <listitem><para><emphasis>Rule Language Mapping</emphasis> :the implementation of the rules.This means that to this language expression the rule will be compiled
+ by the rule engine compiler.</para></listitem>
+ <listitem><para><emphasis>Object</emphasis> :name of the object</para></listitem>
+ <listitem><para><emphasis>Scope</emphasis> :indicates where the expression is
+ targeted: is it for the "condition" part of the rule ,"consequence" part, etc.</para></listitem>
+ </itemizedlist>
+ By clicking on some row's header you can sort the lines in the table according to the clicked row.
+ By double clicking on the line <link linkend="edit_wizard">Edit language mapping Wizard</link> will be open.
+ </entry>
+ </row>
+ <row>
+ <entry>Expression</entry>
+ <entry>Shows the language expression of the selected table line(language message mapping).</entry>
+ </row>
+
+ <row>
+ <entry>Mapping</entry>
+ <entry>Shows the rule of language mapping for the selected table line(language message mapping).</entry>
+ </row>
+ <row>
+ <entry>Object</entry>
+ <entry>Shows the object for the selected table line(language message mapping)</entry>
+ </row>
+
+ <row>
+ <entry id="sort">Sort By</entry>
+ <entry>Using this option you can change the type of lines sorting
+ in the table of language message mappings.To do this select from the drop down lins the method
+ of sorting you want and click <emphasis>Sort</emphasis> button.</entry>
+ </row>
+ <row>
+ <entry>Buttons</entry>
+ <entry><itemizedlist>
+ <listitem><para><emphasis>Edit</emphasis> :by clicking the button users can edit
+ selected in the table of language message mappings lines.For more information look
+ <link linkend="edit_wizard">Edit language mapping Wizard</link>section.</para></listitem>
+ <listitem><para><emphasis>Remove</emphasis> :if you click the button the selected mapping line will be deleted. </para></listitem>
+ <listitem><para><emphasis>Add</emphasis> :with this button you can add new mapping lines to the table.For more information look
+ <link linkend="add_wizard">Add language mapping Wizard</link>section. </para></listitem>
+ <listitem><para><emphasis>Sort</emphasis> : please, for more information go <link linkend="sort">here</link></para></listitem>
+ <listitem><para><emphasis>Copy</emphasis> :with this button you can add new mapping lines to the table
+ in which all the information will be copied from the selected mapping line.</para></listitem>
+ </itemizedlist>
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </table>
+ <section id="edit_wizard">
+ <title>Edit language mapping Wizard</title>
+ <para>This wizard can be opened by double clicking some line
+ in the table of language message mappings or by clicking the <emphasis>Edit</emphasis>button.</para>
+ <para>On the picture below you can see all the options,Edit language mapping Wizard allow to change.</para>
+ <para>Their names as well as the meaning of the options are correspond to the <link linkend="rows">rows</link> of the table.</para>
+ <figure float="0">
+ <title>Edit language mapping Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1c.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>To change the mapping a user should edit the otions he want and finally click <emphasis>Ok</emphasis>.</para>
+ </section>
+ <section id="add_wizard">
+ <title>Add language mapping Wizard</title>
+ <para>This wizard is equal to <link linkend="edit_wizard">Edit language mapping Wizard</link>.
+ It can be opened by clicking the <emphasis>Add</emphasis> button.
+ </para>
+ <para>The only difference is that instead of editing the information you should enter new one.</para>
+ <figure float="0">
+ <title>Add language mapping Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1b.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+ </section>
+ <section id="ruleflow_editor">
+ <title>Flow Editor</title>
+ <para>Drools tools also provide some functionality to define the order in
+ which rules should be executed.Ruleflow file allows you to specify
+ the order in which rule sets should be evaluated using a flow chart.
+ So you can define which rule sets should be evaluated in sequence or in parallel as well as
+ specify conditions under which rule sets should be evaluated.</para>
+ <para>Ruleflows can be set only by using the graphical flow editor which is part of the Drools plugin for Eclipse.
+ Once you have set up a Drools project,you can start adding ruleflows.
+ Add a ruleflow file(.rf) by clicking on the project and selecting "<emphasis>New -> Other...->Flow File</emphasis>":</para>
+ <figure float="0">
+ <title>RuleFlow file creation</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1f.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>By default these ruleflow files (.rf) are opened in the graphical Flow editor.
+ You can see it on the picture below.</para>
+ <figure float="0">
+ <title>Flow Editor</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1g.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>The Flow editor consists of a <emphasis>palette</emphasis>, a <emphasis>canvas</emphasis>
+ and an <emphasis>outline</emphasis> view. To add new elements to the canvas, select the
+ element you would like to create in the palette and then add it to the canvas by clicking on the preferred location.
+ </para>
+ <figure float="0">
+ <title>Adding an element to the canvas</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1e.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>Clicking on the Select option in the palette and
+ then on the element in your ruleflow allows you to
+ view and set the properties of that element in the properies view.</para>
+ <figure float="0">
+ <title>Properties view</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1d.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>Outline View is useful for big complex schemata where not all nodes are seen at one time.
+ So using your Outline view you can easly navigate between parts of a schema. </para>
+ <figure float="0">
+ <title>Outline view usage</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors9.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <section>
+ <title>Different types of control elements in Flow Palette</title>
+ <para>Flow editor supports three types of control elements.
+ They are:</para>
+ <table> <title>Flow Palette Components.Part 1</title>
+ <tgroup cols="3">
+ <colspec align="left" colnum="1" colwidth="1*"></colspec>
+ <colspec align="left" colnum="2" colwidth="1*"></colspec>
+ <colspec align="left" colnum="3" colwidth="3*"></colspec>
+
+ <thead>
+ <row>
+ <entry>Component Picture</entry>
+ <entry>Component Name</entry>
+ <entry>Description</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon7.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Select</entry>
+ <entry>Select a node on the canvas</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon8.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Marquee</entry>
+ <entry>Is used for selecting a group of elements</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon9.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Sequence Flow</entry>
+ <entry>Use this element to join two elements on the canvas</entry>
+ </row>
+ </tbody>
+
+ </tgroup>
+ </table>
+ </section>
+
+ <section>
+ <title>Different types of nodes in Flow Palette</title>
+
+ <para>Currently, ruleflow supports seven types of nodes.
+ In the table below you can find information about them:</para>
+ <table> <title>Flow Palette Components.Part 2.</title>
+ <tgroup cols="3">
+ <colspec align="left" colnum="1" colwidth="1*"></colspec>
+ <colspec align="left" colnum="2" colwidth="1*"></colspec>
+ <colspec align="left" colnum="3" colwidth="3*"></colspec>
+
+ <thead>
+ <row>
+ <entry>Component Picture</entry>
+ <entry>Component Name</entry>
+ <entry>Description</entry>
+ </row>
+
+ </thead>
+ <tbody>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon1.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Start Event</entry>
+ <entry>The start of the ruleflow. A ruleflow should have exactly
+ one start node. The <property moreinfo="none">Start Event</property> can not have incoming
+ connections and should have one outgoing connection. Whenever the ruleflow process is started,
+ the executing is started here and is automatically proceeded to the first node
+ linked to this <property moreinfo="none">Start Event</property></entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon2.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>End Event</entry>
+ <entry>A ruleflow file can have one or more <property moreinfo="none">End Events</property>.
+ The <property moreinfo="none">End Event</property> node should have one incoming connection
+ and can not have outgoing connections. When an end node is reached in the ruleflow,
+ the ruleflow is terminated (including other remaining active nodes when parallelism
+ is used).</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon3.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Rule Task</entry>
+ <entry>represents a set of rules. A <emphasis>Rule Task</emphasis> node should have one
+ incoming connection and one outgoing connection.
+ The <property moreinfo="none">RuleFlowGroup</property> property which is used to specify the name of the
+ ruleflow-group that represents the set of rules of this <emphasis>Rule Task</emphasis> node.
+ When a <emphasis>Rule Task</emphasis> node is reached in the ruleflow, the engine will start
+ executing rules that are a part of the corresponding ruleflow-group.
+ Execution automatically continues to the next node when there are no
+ more active rules in this ruleflow-group.
+ </entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon4.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Gateway[diverge]</entry>
+ <entry>allows you to create branches in your ruleflow.
+ A <property moreinfo="none">Gateway[diverge]</property> node should have one incoming connection and two or more
+ outgoing connections.</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon4.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Gateway[converge]</entry>
+ <entry>allows you to synchronize multiple branches.
+ A <property moreinfo="none">Gateway[diverge]</property>node should have two or more incoming connections and one
+ outgoing connection.</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon5.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Reusable Sup-Process</entry>
+ <entry>represents the invocation of another ruleflow from this ruleflow.
+ A subflow node should have one incoming connection and one outgoing connection.
+ It contains the property "processId" which specifies the id of the process that should be executed.
+ When a <property moreinfo="none">Reusable Sup-Process</property> node is reached in the ruleflow, the engine will start the process with the given id.
+ The subflow node will only continue if that subflow process has terminated its execution.
+ Note that the subflow process is started as an independent process,
+ which means that the subflow process will not be terminated if this process reaches an end node.</entry>
+ </row>
+ <row>
+ <entry><inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/icon6.png"></imagedata>
+ </imageobject></inlinemediaobject></entry>
+ <entry>Script Task</entry>
+ <entry>represents an action that should be executed in this ruleflow.
+ An <property moreinfo="none">Script Task</property> node should have one incoming connection and one outgoing
+ connection. It contains the property "action" which specifies the action that should be executed.
+ When a <property moreinfo="none">Script Task</property> node is reached in the ruleflow, it will execute the action and
+ continue with the next node. An action should be specified as a piece of (valid)
+ MVEL code. </entry>
+ </row>
+
+ </tbody>
+ </tgroup>
+ </table>
+ </section>
+ </section>
+
+ <section id="textual_rule_editor">
+ <title>The Rule Editor</title>
+
+ <para>The <property moreinfo="none">Rule editor</property> works on files that have a <emphasis>
+ <property moreinfo="none">.drl</property>
+ </emphasis> (or <emphasis>
+ <property moreinfo="none">.rule</property>
+ </emphasis> in the case of spreading rules across multiple rule files) extension.</para>
+
+ <figure float="0">
+ <title>New Rule</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors1.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The editor follows the pattern of a normal text editor in eclipse, with all the normal
+ features of a text editor:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>
+ <link linkend="rules_editor_content_assist">Content Assist</link>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <link linkend="rules_editor_code_folding">Code Folding</link>
+ </para>
+ </listitem>
+
+ <!-- <listitem>
+ <para>
+ <link linkend="rules_editor_error_reporting">Error Reporting</link>
+ </para>
+ </listitem>-->
+
+ <listitem>
+ <para>
+ <link linkend="rules_editor_sync_with_outline">Synchronization with Outline
+ View</link>
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <section id="rules_editor_content_assist">
+ <title>Content Assist</title>
+
+ <para>While working in the <property moreinfo="none">Rule editor</property> you can get a content
+ assistance the usual way by pressing <emphasis>
+ <property moreinfo="none">Ctrl + Space</property>.</emphasis></para>
+
+ <para>Content Assist shows all possible keywords for the current cursor position.</para>
+
+ <figure float="0">
+ <title>Content Assist Demonstration</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Content Assist inside of the <emphasis>
+ <property moreinfo="none">Message</property>
+ </emphasis> suggests all available fields.</para>
+
+ <figure float="0">
+ <title>Content Assist Demonstration</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ </section>
+
+ <section id="rules_editor_code_folding">
+ <title>Code Folding</title>
+
+ <para>Code folding is also available in the <property moreinfo="none">Rule editor</property>. To
+ hide/show sections of the file use the icons with minus/plus on the left vertical
+ line of the editor.</para>
+
+ <figure float="0">
+ <title>Code Folding</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors4.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ </section>
+
+ <!--section id="rules_editor_error_reporting">
+ <title>Error Reporting</title>
+
+ </section-->
+
+ <section id="rules_editor_sync_with_outline">
+ <title>Synchronization with Outline View</title>
+
+ <para>The <property moreinfo="none">Rule editor</property> works in synchronization with the
+ <property moreinfo="none">Outline view</property> which shows the structure of the rules,
+ imports in the file and also globals and functions if the file has them.</para>
+
+ <figure float="0">
+ <title>Synchronization with Outline View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors5.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The view is updated on save. It provides a quick way of navigating around rules by
+ names in a file which may have hundreds of rules. The items are sorted
+ alphabetically by default.</para>
+ </section>
+
+ <section id="rete_view">
+ <title>The Rete Tree View</title>
+
+ <para>The <property moreinfo="none">Rete Tree view</property> shows you the current Rete Network for
+ your <emphasis>
+ <property moreinfo="none">.drl</property>
+ </emphasis> file. Just click on the <emphasis>
+ <property moreinfo="none">Rete Tree tab</property>
+ </emphasis> at the bottom of the <property moreinfo="none">Rule editor</property>.</para>
+
+ <figure float="0">
+ <title>Rete Tree</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors6.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Afterwards you can generate the current Rete Network visualization. You can push
+ and pull the nodes to arrange your optimal network overview.</para>
+ <para>If you got hundreds of nodes, select some of them with a frame. Then you can pull
+ groups of them.</para>
+
+ <figure float="0">
+ <title>Selecting the nodes in the Rete Tree with Frame</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors7.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>You can zoom in and out the Rete tree in case not all nodes are shown in the
+ current view. For this use the combo box or "+" and "-" icons on the toolbar.</para>
+
+ <figure float="0">
+ <title>Rete Tree Zooming</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/editors/editors8.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <note>
+ <title>Note:</title>
+
+ <para>The <property moreinfo="none">Rete Tree view</property> works only in Drools Rule Projects,
+ where the Drools Builder is set in the project properties.</para>
+ </note>
+ <para>We hope, this guide helped you to get started with the JBoss BPMN
+ Convert module. Besides, for additional information you are welcome on
+ <ulink url="http://www.jboss.com/index.html?module=bb&op=viewforum&f=201">JBoss forum</ulink>.</para>
+ </section>
+
+ </section>
+
+</chapter>
+
+
+
+</book>
Modified: branches/jbosstools-3.1.x/drools/docs/reference/pom.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/reference/pom.xml 2010-03-04 11:32:52 UTC (rev 20643)
+++ branches/jbosstools-3.1.x/drools/docs/reference/pom.xml 2010-03-04 11:43:11 UTC (rev 20644)
@@ -11,45 +11,35 @@
<name>Drools_Tools_Reference_Guide</name>
<profiles>
- <profile>
- <id>release</id>
- <properties>
- <master>master_output.xml</master>
- <xsl-single>classpath:/xslt/org/jboss/tools/xhtml-single-release.xsl</xsl-single>
- <xsl-chunked>classpath:/xslt/org/jboss/tools/xhtml-release.xsl</xsl-chunked>
- <xsl-pdf>classpath:/xslt/org/jboss/tools/pdf.xsl</xsl-pdf>
- </properties>
- </profile>
- <profile>
- <id>releaseTest</id>
- <properties>
- <master>master_output.xml</master>
- <xsl-single>classpath:/xslt/org/jboss/tools/xhtml-single-release-nomarker.xsl</xsl-single>
- <xsl-chunked>classpath:/xslt/org/jboss/tools/xhtml-release-nomarker.xsl</xsl-chunked>
- <xsl-pdf>classpath:/xslt/org/jboss/tools/pdf.xsl</xsl-pdf>
- </properties>
- </profile>
- <profile>
- <id>releaseJBDS</id>
- <properties>
- <master>master_output.xml</master>
- <xsl-single>classpath:/xslt/com/jboss/tools/xhtml-single-release.xsl</xsl-single>
- <xsl-chunked>classpath:/xslt/com/jboss/tools/xhtml-release.xsl</xsl-chunked>
- <xsl-pdf>classpath:/xslt/com/jboss/tools/pdf.xsl</xsl-pdf>
- <cssdir>../../../documentation/jbosstools-jdocbook-style/src/main/com/css/</cssdir>
- </properties>
- </profile>
- <profile>
- <id>diffmk</id>
- <properties>
- <master>master_output.xml</master>
- <xsl-single>classpath:/xslt/org/jboss/tools/xhtml-single-diff.xsl</xsl-single>
- <xsl-chunked>classpath:/xslt/org/jboss/tools/xhtml-diff.xsl</xsl-chunked>
- <xsl-pdf>classpath:/xslt/org/jboss/tools/pdf-diff.xsl</xsl-pdf>
- </properties>
- </profile>
- </profiles>
-
+ <profile>
+ <id>release</id>
+ <properties>
+ <master>master_output.xml</master>
+ <xsl-single>classpath:/xslt/org/jboss/tools/xhtml-single-release.xsl</xsl-single>
+ <xsl-chunked>classpath:/xslt/org/jboss/tools/xhtml-release.xsl</xsl-chunked>
+ <xsl-pdf>classpath:/xslt/org/jboss/tools/pdf.xsl</xsl-pdf>
+ </properties>
+ </profile>
+ <profile>
+ <id>releaseJBDS</id>
+ <properties>
+ <master>master.xml</master>
+ <xsl-single>classpath:/xslt/com/jboss/tools/xhtml-single-release.xsl</xsl-single>
+ <xsl-chunked>classpath:/xslt/com/jboss/tools/xhtml-release.xsl</xsl-chunked>
+ <xsl-pdf>classpath:/xslt/com/jboss/tools/pdf.xsl</xsl-pdf>
+ <cssdir>../../../documentation/jbosstools-jdocbook-style/src/main/com/css/</cssdir>
+ </properties>
+ </profile>
+ <profile>
+ <id>diffmk</id>
+ <properties>
+ <master>master_output.xml</master>
+ <xsl-single>classpath:/xslt/org/jboss/tools/xhtml-single-diff.xsl</xsl-single>
+ <xsl-chunked>classpath:/xslt/org/jboss/tools/xhtml-diff.xsl</xsl-chunked>
+ <xsl-pdf>classpath:/xslt/org/jboss/tools/pdf-diff.xsl</xsl-pdf>
+ </properties>
+ </profile>
+ </profiles>
<build>
<plugins>
<plugin>
14 years, 10 months
JBoss Tools SVN: r20642 - in branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US: images and 2 other directories.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 06:12:59 -0500 (Thu, 04 Mar 2010)
New Revision: 20642
Added:
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Author_Group.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Book_Info.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.ent
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Preface.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Revision_History.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/conclusion.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/functionality_overview.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/guvnor_preferences.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/add_toGuvnor_wizard.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/association_details.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version2.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version3.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/confirm_delete.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/delete_connection_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/do_into_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_back_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_home_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_defaultPackage.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_button.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_wizard.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_repository.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnorinfo.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/open_guvnor_perspectine.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/repository_files_properties.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor2.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor3.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view2.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view3.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/select_target_folder.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection1.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection2.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/guvnor_preferences/
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/guvnor_preferences/guvnor_preferences.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/jbosstools_logo.png
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/introduction.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master.xml
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master_output.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Author_Group.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Author_Group.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Author_Group.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,5 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<authorgroup><author><firstname>John</firstname><surname>Graham</surname><email>jgraham(a)redhat.com</email></author>
+ <author><firstname>Olga</firstname><surname>Chikvina</surname></author> </authorgroup>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Book_Info.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Book_Info.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Book_Info.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,4 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<bookinfo><title>Eclipse Guvnor Tools Reference Guide</title><subtitle>Provides information relating to the Eclipse Guvnor Tools set.</subtitle><productname>JBoss Developer Studio</productname><productnumber>3.0</productnumber><edition>1.0</edition><pubsnumber>0</pubsnumber><abstract><para>The Eclipse Guvnor Tools Reference Guide explains how to use the Eclipse Guvnor Tools to gain access to resources controled by the Guvnor repository policies.</para></abstract><corpauthor><inlinemediaobject><imageobject><imagedata fileref="Common_Content/images/title_logo.svg" format="SVG"></imagedata></imageobject></inlinemediaobject></corpauthor><xi:include href="Common_Content/Legal_Notice.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include><xi:include href="Author_Group.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include></bookinfo>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.ent
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.ent (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.ent 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,4 @@
+<!ENTITY PRODUCT "JBoss">
+<!ENTITY BOOKID "Eclipse_Guvnor_Tools_Reference_Guide">
+<!ENTITY YEAR "2010">
+<!ENTITY HOLDER "Red Hat">
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Eclipse_Guvnor_Tools_Reference_Guide.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,12 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<book>
+<xi:include href="Book_Info.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="Preface.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="introduction.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="functionality_overview.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="guvnor_preferences.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="conclusion.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+<xi:include href="Revision_History.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include>
+</book>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Preface.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Preface.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Preface.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,4 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<preface><title>Preface</title><xi:include href="Common_Content/Conventions.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include><xi:include href="Feedback.xml" xmlns:xi="http://www.w3.org/2001/XInclude"><xi:fallback xmlns:xi="http://www.w3.org/2001/XInclude"><xi:include href="Common_Content/Feedback.xml" xmlns:xi="http://www.w3.org/2001/XInclude"></xi:include></xi:fallback></xi:include></preface>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Revision_History.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Revision_History.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/Revision_History.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,4 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<appendix><title>Revision History</title><simpara><revhistory><revision><revnumber>0</revnumber><date>Fri Nov 20 2009</date><author><firstname>Isaac</firstname><surname>Rooskov</surname><email>irooskov(a)redhat.com</email></author><revdescription><simplelist><member>Initial creation of book by publican</member></simplelist></revdescription></revision></revhistory></simpara></appendix>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/conclusion.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/conclusion.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/conclusion.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,22 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="conclusion" xreflabel="conclusion">
+ <?dbhtml filename="conclusion.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Conclusion</title>
+
+ <para>As stated at the beginning of this document, the key goal of the <property>EGT</property>
+ is to provide a way of interacting with Guvnor repository resources in a local Eclipse
+ workspace. While clearly there is a lot more that could be done, and no doubt there will be
+ aspects of the current tooling that require revision going forward, we feel that the current
+ state of the <property>EGT</property> is sufficient for the major use cases.</para>
+
+ <para>If you have some questions, comments or suggestions on the topic, please feel free to ask in the
+ <ulink url="http://www.jboss.org/index.html?module=bb&op=viewforum&f=201"
+ >Jboss Tools Forum</ulink>.</para>
+</chapter>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/functionality_overview.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/functionality_overview.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/functionality_overview.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,727 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="functionality_overview" xreflabel="functionality_overview">
+ <?dbhtml filename="functionality_overview.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Functionality Overview</title>
+
+ <para>This chapter will introduce you to the <property>Guvnor Repository Exploring
+ perspective</property> and give an overview on all functionality the <property>Guvnor Tools</property> provides.</para>
+
+ <section id="guvnor_perspective">
+ <title>Guvnor Perspective</title>
+
+ <para>The <property>Guvnor Repository Exploring perspective</property> contains two views
+ supplied by <property>EGT</property> – <property>Repository Explorer</property> and
+ <property>Version History</property>, that will be the center of most interaction
+ with Guvnor, and Eclipse standard views such as <property>Properties</property> and
+ <property>Resource Navigator</property> that are also useful.</para>
+
+ <para>While each of these views can be opened and positioned independently within an Eclipse
+ workbench, the <property>Guvnor perspective</property> provides a convenient method of
+ getting a suggested layout. In the Eclipse workbench menu, choose <emphasis>
+ <property>Window > Open Perspective > Other</property>
+ </emphasis> to get the perspective list:</para>
+
+ <figure>
+ <title>Enabling the Guvnor Repository Perspective</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/open_guvnor_perspectine.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>And then choose <emphasis>
+ <property>Guvnor Repository Exploring</property>.</emphasis> This opens the
+ <property>Guvnor perspective</property>.</para>
+ </section>
+
+ <section id="connection_wizard">
+ <title>Guvnor Connection Wizard</title>
+
+ <para>After opening the <property>Guvnor perspective</property>, the first task is to make a
+ connection to a Guvnor repository. This is handled by the <property>Guvnor Connection
+ wizard</property>. This wizard appears in a number of places within the
+ <property>EGT</property> (as detailed below), but in this section we will cover only
+ the two most basic entry points.</para>
+
+ <para>The <property>Guvnor Connection wizard</property> can be started in the following
+ ways:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>using the Eclipse menu <emphasis>
+ <property>File > New > Other > Guvnor > Guvnor
+ repository location</property>
+ </emphasis></para>
+
+ <figure>
+ <title>New Guvnor Repository Location</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/start_guvnor_connection1.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </listitem>
+
+ <listitem>
+ <para>in the <property>Guvnor Repositories view</property> using the drop-down menu</para>
+
+ <figure>
+ <title>Adding New Guvnor Connection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/start_guvnor_connection2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </listitem>
+
+ <listitem>
+ <para>using the menu button
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_connection_button.png"/>
+ </imageobject>
+ </inlinemediaobject> )
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Choosing either of these will start the <property>Guvnor Connection
+ wizard</property>.</para>
+
+ <figure id="guvnor_connection_wizard">
+ <title>Guvnor Connection Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_connection_wizard.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Default values appear in the <emphasis>
+ <property>Location</property>,</emphasis>
+ <emphasis>
+ <property>Port</property>,</emphasis> and <emphasis>
+ <property>Repository</property>
+ </emphasis> fields (See the <link linkend="guvnor_preferences">“Guvnor Preferences”</link> section below for details about how to
+ change these default values.) Of course, any of these fields can be edited by typing in
+ the corresponding text box. Drag-and-drop or paste into the <emphasis>
+ <property>Location</property>
+ </emphasis> field of a typical Guvnor repository URL such as:</para>
+
+ <para>
+ <emphasis>
+ <property>http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/webdav</property>
+ </emphasis>
+ </para>
+
+ <para>Results in the URL being parsed into the respective fields as well. The authentication
+ information (user name and password) can optionally be stored in the Eclipse
+ workbench's key-ring file based on the selection of <emphasis>
+ <property>Save user name and password</property>.</emphasis></para>
+
+ <note>
+ <title>Note:</title>
+ <para>If the authentication information is not stored in the key-ring, then the
+ <property>EGT</property> uses a session authentication, what means that the
+ credentials supplied are used only for the lifetime of the Eclipse workbench
+ instance.</para>
+ </note>
+
+ <para>If authentication information is not stored in the key-ring or the authentication
+ information (key-ring or session) is not valid, the <property>EGT</property> will prompt
+ for authentication information when it has to access the Guvnor repository.</para>
+
+ <para>If authentication fails, the <property>EGT</property> will retry once and then issue
+ an authentication failure error.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para>If an authentication failure error occurs, you can retry the same operation and
+ supply different authentication information.</para>
+ </tip>
+
+ <para>Note that the <property>EGT</property> calls the Guvnor repository at various times,
+ such as when determining if resource updates are available. Thus if you use session
+ authentication, the authentication dialog will appear at different times during the
+ Eclipse workbench session, depending on what actions you take. For ease of use, we
+ recommend saving the authentication information in the Eclipse key-ring.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>The Eclipse key-ring file is distinct from key-ring files found in some platforms
+ such as Mac OS X and many forms of Linux. Thus, sometimes if you access a Guvnor
+ repository outside the <property>EGT</property>, the key-ring files might become
+ unsynchronized and you will be unexpectedly prompted for authentication in Eclipse.
+ This is nuisance, but your usual credentials should apply in this case.</para>
+ </note>
+ </section>
+
+ <section id="guvnor_repositories_view">
+ <title>Guvnor Repositories View</title>
+
+ <para>The <property>Guvnor Repositories view</property> contains tree structures for Guvnor
+ repository contents.</para>
+
+ <figure>
+ <title>Guvnor Repositories View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_repository.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>You can perform the following actions under the resources in the
+ <property>Guvnor Repositories view</property>:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>create a new Guvnor repository connection. How to do this is describe above in the <link linkend="connection_wizard">"Guvnor Connection Wizard"</link> section.</para>
+ </listitem>
+
+ <listitem>
+ <para>remove a Guvnor repository connection. Use the Delete button
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/delete_connection_button.png"/>
+ </imageobject>
+ </inlinemediaobject> ) in the tool-bar or the <emphasis>
+ <property>Delete</property></emphasis> option in the context menu to remove a repository connection.</para>
+ </listitem>
+
+ <listitem>
+ <para>refresh Guvnor repository resorces. Use the <emphasis>
+ <property>Refresh</property></emphasis> context menu item to reload a tree content for the selected node.</para>
+ </listitem>
+
+ <listitem>
+ <para>make use of "drill-into" functionality. It's represented by a number of tool-bar/context menu items such as <emphasis><property>Go Home</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_home_button.png"/>
+ </imageobject>
+ </inlinemediaobject> ), <emphasis><property>Go Back</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_back_button.png"/>
+ </imageobject>
+ </inlinemediaobject> ) and <emphasis>
+ <property>Go Into</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_into_button.png"/>
+ </imageobject>
+ </inlinemediaobject> ).</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Drill-down is useful when working with deeply nested tree structures and when you wish to concentrate on only branch of the tree. For example, drilling into the <emphasis>
+ <property>"defaultPackage"</property></emphasis> node changes the tree view to:</para>
+
+ <figure>
+ <title>Going Into the <emphasis>"defaultPackage"</emphasis></title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_into_defaultPackage.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Clicking on the Go Home button ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_home_button.png"/>
+ </imageobject>
+ </inlinemediaobject> ) or selecting <emphasis>
+ <property>Go Home</property></emphasis> in the context menu returns the tree to the top-level structure shown in the previous picture above.
+ </para>
+
+ <para>There are a number of operations that can be performed on Guvnor repository files. Selecting a file in
+the Guvnor repository causes the Eclipse <property>Properties view</property> to update with details about that file:
+</para>
+
+ <figure>
+ <title>Guvnor Repository Files Properties</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/repository_files_properties.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para></para>
+ </section>
+
+ <section id="local_copies">
+ <title>Local Copies of Guvnor Files</title>
+
+ <para>As mentioned in the <link linkend="introduction">"Introduction"</link>, the main purpose
+ of the <property>EGT</property> is to allow development using resources held in a Guvnor
+ repository. There are two method of getting local copies of Guvnor repository
+ resources:</para>
+
+ <orderedlist>
+ <listitem>
+ <para>Drag-and-drop from the <property>Guvnor Repositories view</property></para>
+ </listitem>
+ <listitem>
+ <para>Using the <link linkend="resources_from_guvnor">Import from Guvnor
+ wizard</link>, as described further in this document</para>
+ </listitem>
+ </orderedlist>
+
+ <para>When local copies of Guvnor repository files are created, the <property>EGT</property>
+ sets an association between the local copy and the master file in the repository. This
+ information is kept in the (normally) hidden <emphasis>
+ <property>.guvnorinfo</property>
+ </emphasis> folder in the local project and, like all metadata, should not be changed by
+ end users.</para>
+
+ <figure>
+ <title>.guvnorinfo metadata</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnorinfo.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The association allows for operations such as update and commit in
+ synchronization with the master copy held in the Guvnor repository.</para>
+
+ <para>The <property>EGT</property> decorates local resources associated with Guvnor
+ repository master copies. This decoration appears in Eclipse views conforming to the
+ Eclipse Common Navigator framework, such as the Eclipse <property>Resource
+ Navigator</property> and the Java <property>Package Explorer</property>. On the image
+ above you can see the <emphasis>
+ <property>Dummy rule.drl</property></emphasis> file with the decoration in the <property>Resource Navigator</property>. The Guvnor icon decorator is on the top right of the file image, and the Guvnor
+ revision details are appended to the file name. (The presence/location of these can be
+ changed the <link linkend="resource_decoration_preferences">Guvnor
+ Preferences</link>.)</para>
+
+ <para>Here we see that, <emphasis><property>Dummy role.drl</property></emphasis> is associated with a Guvnor repository
+ resource and the local copy is based on revision 0, with a <code>02-10-2008, 4:21:53</code> date/time
+ stamp. The file <emphasis><property>Sample.drl</property>,</emphasis> however, is not associated with a Guvnor repository
+ file. Further details about the association can be found in the standard Eclipse
+ properties page, accessed via the <emphasis><property>Properties</property></emphasis> option in the context menu:</para>
+
+ <figure>
+ <title>Association Details</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/association_details.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The <property>EGT</property> contributes a property page to the standard Eclipse
+ properties dialog, the contents of which are shown above. It displays the specific Guvnor
+ repository, the location within the repository, the version (date/time stamp) and
+ the revision number.</para>
+ </section>
+
+ <section id="actions">
+ <title>Actions for Local Guvnor Resources</title>
+
+ <para>The <property>EGT</property> provides a number of actions (available through the
+ <emphasis><property>Guvnor</property></emphasis> context menu on files) for working with files, both those associated with
+ Guvnor repository master copies and those not associated. The actions are:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>
+ <link linkend="update_action">Update</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="add_action">Add</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="commit_action">Commit</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="show_history_action">Show History</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="compare_with_version">Compare with Version</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="switch_to_version">Switch to Version</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="delete_action">Delete</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="disconnect_action">Disconnect</link>
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Each of these actions is described below.</para>
+
+ <section id="update_action">
+ <title>Update Action</title>
+
+ <para>The <emphasis>
+ <property>Update</property>
+ </emphasis> action is available for one or more Guvnor resources that are not in
+ synchronization with the Guvnor repository master copies. These resources would not
+ be in synchronization because either/both</para>
+
+ <orderedlist>
+ <listitem><para>There are local changes to these
+ resources</para></listitem>
+ <listitem><para>The master copies have been changed in the Guvnor repository</para></listitem>
+ </orderedlist>
+
+ <para>Performing the <emphasis>
+ <property>Update</property>
+ </emphasis> action replaces the local file contents with the current contents from
+ the Guvnor repository master copies (equivalent to <emphasis>
+ <link linkend="switch_to_version">Switch to version</link>
+ </emphasis> for the latest version).</para>
+ </section>
+
+ <section id="add_action">
+ <title>Add Action</title>
+
+ <para>The <emphasis>
+ <property>Add</property>
+ </emphasis> action is available for one or more local files that are not associated
+ with a Guvnor repository master copy. Choosing the <emphasis>
+ <property>Add</property>
+ </emphasis> action launches the <property>Add to Guvnor wizard</property>:</para>
+
+ <figure>
+ <title>Add to Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The first page of the wizard asks for the selection of the target Guvnor
+ repository and gives the choice to create a new Guvnor repository connection (in
+ which case the second page is the same as the <link linkend="guvnor_connection_wizard"
+ >Guvnor Connection wizard</link>). Once the target Guvnor repository is chosen,
+ the wizard then asks for the folder location to add the selection files:</para>
+
+ <figure>
+ <title>Selecting a Target Folder</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/select_target_folder.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Here the <emphasis>
+ <property>"defaultPackage"</property></emphasis> folder is selected as the destination
+ location.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>Note that the <emphasis>
+ <property>"snapshot"</property></emphasis> folder in the Guvnor repository is read-only for
+ <property>EGT</property>, and hence not visible as a candidate location in
+ this wizard. The Guvnor repository web administration tools must be used to add
+ snapshot content.</para>
+ </note>
+
+ <para>Clicking on <emphasis>
+ <property>Finish</property>
+ </emphasis> adds the selected files to the Guvnor repository and creates an
+ association between the local and Guvnor repository files.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>Note that the wizard will not allow for overwrite of existing Guvnor
+ repository files. Another target location must be chosen.</para>
+ </note>
+ </section>
+
+ <section id="commit_action">
+ <title>Commit Action</title>
+
+ <para>The <emphasis>
+ <property>Commit</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files
+ that have local changes. The <emphasis>
+ <property>Commit</property>
+ </emphasis> action will write the local changes back to the associated Guvnor
+ repository files and update the association for the new revision created.</para>
+
+ <para>If a local change is based on an older revision of a file that is currently in the
+ Guvnor repository (for example, someone else changed the same file), then the <emphasis>
+ <property>Commit</property>
+ </emphasis> action will<figure>
+ <title>Add to Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure> ask whether you wish to overwrite the current version in the
+ Guvnor repository with the local content. When such conflicts occur, however, you
+ should use the Eclipse Guvnor version tools, along with Eclipse standard tools, to
+ determine the differences and merge content based on the current version in the
+ Guvnor repository.</para>
+ </section>
+
+ <section id="show_history_action">
+ <title>Show History Action</title>
+
+ <para>The <emphasis>
+ <property>Show History</property>
+ </emphasis> action is enable for one Guvnor repository associated file and causes
+ the <link linkend="guvnor_history_view">Guvnor Resource History view</link> to be
+ populated with revision history for the selected file.</para>
+ </section>
+
+ <section id="compare_with_version">
+ <title>Compare with Version Action</title>
+
+ <para>The <emphasis>
+ <property>Compare with Version</property>
+ </emphasis> action is enabled for one Guvnor repository associated file. This action
+ first opens a wizard asking for the version for comparison (with the local file
+ contents):</para>
+
+ <figure>
+ <title>Compare with Version Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the revision is selected, the action opens the Eclipse <property>Compare
+ editor</property> (read-only):</para>
+ <figure>
+ <title>Eclipse Compare Editor</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>This editor uses Eclipse-standard comparison techniques to show the differences in
+ the two versions. In cases where there are no differences, the editor will not open,
+ rather a dialog saying that there are no differences will appear.</para>
+ <figure>
+ <title>Alert Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version3.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+
+ <section id="switch_to_version">
+ <title>Switch to Version Action</title>
+
+ <para>The <emphasis>
+ <property>Switch to Version</property>
+ </emphasis> action is enabled for one Guvnor repository associated file.</para>
+ <para>First the <emphasis>
+ <property>Switch to Version</property>
+ </emphasis> action prompts for selection of version:</para>
+
+ <figure>
+ <title>Select Version Window</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the version is selected, the <emphasis>
+ <property>Switch to Version</property>
+ </emphasis> action replaces the local file contents with those from the revision
+ selected.</para>
+ </section>
+
+ <section id="delete_action">
+ <title>Delete Action</title>
+
+ <para>The <emphasis>
+ <property>Delete</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files.
+ After confirmation via a dialog, the <emphasis>
+ <property>Delete</property>
+ </emphasis> action removes the files in the Guvnor repository and deletes local
+ metadata for the Guvnor repository association.</para>
+
+ <figure>
+ <title>Comfirm Delete Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/confirm_delete.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+
+ <section id="disconnect_action">
+ <title>Disconnect Action</title>
+
+ <para>The <emphasis>
+ <property>Disconnect</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files,
+ and removes local metadata for the Guvnor repository association.</para>
+ </section>
+ </section>
+
+ <section id="guvnor_history_view">
+ <title>Guvnor Resource History View</title>
+
+ <para>The <property>Guvnor Resource History view</property> should details about revision
+ history for selected files, both local and those in Guvnor repositories. The initial
+ state of this view is shown on the figure below.</para>
+
+ <figure>
+ <title>Initial State of the Guvnor Resource History View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The <property>Guvnor Resource History view</property> is populated by <emphasis>
+ <property>Show History</property>
+ </emphasis> actions in either the local <emphasis>
+ <property>Guvnor</property></emphasis> context menu or in the context menu for
+ a Guvnor repository file in the <link linkend="guvnor_repositories_view">Guvnor
+ Repositories view</link>. Once this action is performed, the <property>Guvnor
+ Resource History view</property> updates to show the revision history:</para>
+
+ <figure>
+ <title>IGuvnor Resource History View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Here we see that the file <emphasis>
+ <property>test.txt</property>
+ </emphasis> has three revisions. Double clicking on a revision row (or the context menu <emphasis>
+ <property>Open (Read only)</property>)</emphasis> opens an Eclipse read-only editor
+ with the revision contents.</para>
+
+ <figure>
+ <title>Eclipse Read-only Editor with the Revision Contents</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view3.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <note>
+ <title>Note:</title>
+ <para>You can also use the <emphasis>
+ <property>Save As...</property>
+ </emphasis> option when a file is open in a read-only editor to save a local
+ writable copy of the contents. Doing so, however, will not associate the file
+ created with its Guvnor source.</para>
+ </note>
+
+ </section>
+
+ <section id="resources_from_guvnor">
+ <title>Importing Guvnor Repository Resources</title>
+
+ <para>In addition to the single file drag-and-drop from the <property>Guvnor Repositories
+ view</property>, the <property>EGT</property> also includes a wizard for copying one
+ or more files from a Guvnor repository to the local workspace (and setting the
+ association with the Guvnor repository). This wizard is available from the <emphasis>
+ <property>File > Import > Guvnor > Resource from
+ Guvnor</property>
+ </emphasis> and the <emphasis>
+ <property>File > New > Other > Guvnor > Resource from
+ Guvnor</property>
+ </emphasis> menu items.</para>
+ <note>
+ <title>Note:</title>
+
+ <para>Note that the wizard is identical but appears in both locations to accommodate
+ users who tend to view this functionality as being in either category.</para>
+ </note>
+
+ <para>The first page of the wizard asks for the selection of the source Guvnor repository
+ and gives the choice to create a new Guvnor repository connection (in which case the
+ second page is the same as the <link linkend="guvnor_connection_wizard">Guvnor Connection wizard</link>).</para>
+
+ <figure>
+ <title>Resource from Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the source Guvnor repository is chosen, the wizard prompts for resource selection:</para>
+
+ <figure>
+ <title>Resource Selection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Finally, the target location in the local workspace should be chosen:</para>
+ <figure>
+ <title>Choosing the Target Location</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>On completion the wizard copies the selected files from the Guvnor repository to the local workspace.
+ If a file with the same name already exists in the destination, the wizard uses the Eclipse standard
+ "prompt for rename" dialog:</para>
+
+ <figure>
+ <title>Prompt for Rename Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor3.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+</chapter>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/guvnor_preferences.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/guvnor_preferences.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/guvnor_preferences.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,90 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="guvnor_preferences" xreflabel="guvnor_preferences">
+ <?dbhtml filename="guvnor_preferences.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Guvnor Preferences</title>
+
+ <para>The <property>EGT</property> provides a preference page in the <emphasis>
+ <property>Guvnor</property>
+ </emphasis> category:</para>
+
+ <figure>
+ <title>Resource Selection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/guvnor_preferences/guvnor_preferences.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The preferences cover two categories:</para>
+ <itemizedlist>
+ <listitem><para>Guvnor repository connections</para></listitem>
+
+ <listitem><para>Local Guvnor
+ repository resource decorations.</para></listitem>
+ </itemizedlist>
+
+ <section id="repo_connection_preferences">
+ <title>Guvnor Repository Connection Preferences</title>
+ <para>There are two preferences that can be set for Guvnor repository connections, that are
+ used when creating new connections:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>The first is a default Guvnor repository URL template, which can make it
+ easier to create multiple similar connections by simply changing part of the
+ field, such as the host name.</para>
+ </listitem>
+ <listitem>
+ <para>The second is whether saving of authentication information in the Eclipse
+ platform key-ring should be enabled by default.</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>As with the Guvnor repository URL template, actually whether to save a specific
+ instance of authentication information in the Eclipse platform key-ring can be
+ determined when actually creating the connection. That is, both of these preferences are
+ simply convenience values set to reasonable defaults.</para>
+ </section>
+
+ <section id="resource_decoration_preferences">
+ <title>Local Guvnor Repository Resource Decoration Preferences</title>
+
+ <para>The second category of preferences provided by the <property>EGT</property> deals with how the decoration of
+ local resources associated with Guvnor repository resources is presented. Since the
+ Guvnor repository is not a substitute for a SCM, and since SCM tools in Eclipse tend to
+ decorate local resources, it is useful to be able to control just how the <property>EGT</property> decorate
+ its local resources to avoid messy conflicts with SCM packages.</para>
+
+ <para>In the <emphasis>
+ <property>File Decoration</property></emphasis>
+ section of the preference page, you can choose the location (Top right, Top left, Bottom right,
+ Bottom left) of the decoration icon, or you can choose not to display it. In
+ the <emphasis>
+ <property>Text</property></emphasis> section, you can format the Guvnor metadata that is appended to the file
+ names:</para>
+ <itemizedlist>
+ <listitem>
+ <para>Whether to show an indicator (>) when the local file has changes not committed back to the
+ Guvnor repository</para>
+ </listitem>
+ <listitem>
+ <para>Whether to show the revision number</para>
+ </listitem>
+ <listitem>
+ <para>Whether to show the date/time stamp</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Any changes to these preferences take effect immediately upon clicking the <emphasis>
+ <property>Apply</property></emphasis> and then <emphasis>
+ <property>Ok</property></emphasis> buttons.</para>
+ </section>
+</chapter>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/add_toGuvnor_wizard.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/add_toGuvnor_wizard.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/association_details.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/association_details.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version2.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version2.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version3.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/compare_with_version3.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/confirm_delete.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/confirm_delete.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/delete_connection_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/delete_connection_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/do_into_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/do_into_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_back_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_back_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_home_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_home_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_defaultPackage.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/go_into_defaultPackage.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_button.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_wizard.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_connection_wizard.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_repository.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnor_repository.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnorinfo.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/guvnorinfo.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/open_guvnor_perspectine.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/open_guvnor_perspectine.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/repository_files_properties.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/repository_files_properties.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor2.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor2.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor3.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_from_guvnor3.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view2.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view2.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view3.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/resource_history_view3.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/select_target_folder.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/select_target_folder.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection1.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection1.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection2.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/functionality_overview/start_guvnor_connection2.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/guvnor_preferences/guvnor_preferences.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/guvnor_preferences/guvnor_preferences.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/jbosstools_logo.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/images/jbosstools_logo.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/introduction.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/introduction.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/introduction.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,177 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<chapter id="introduction" xreflabel="introduction">
+ <title>Introduction</title>
+
+ <para>The purpose of this document is to describe briefly the functionality present in the
+ <property>Eclipse Guvnor Tools</property> (EGT) for Drools 5. While not intended as a
+ comprehensive reference, there should be enough detail included for early adopters using
+ these tools.</para>
+
+ <para>The <property>Guvnor repository</property> is not intended as a Source Code Management
+ (SCM) solution, and the <property>EGT</property> are not intended to be Eclipse “team
+ provider” extensions or replacements. Rather, the Guvnor repository is a location where
+ certain artifacts (such as rules and SOA policy definitions) are controlled (“governed”) by
+ policies defined by the deployment environment. The purpose of the <property>EGT</property>
+ is then to enable access to resources held by the Guvnor repository, so
+ they can be used in development. Thus, limited capabilities for reading, writing, adding,
+ and removing Guvnor repository resources are provided in the
+ <property>EGT</property>.</para>
+
+ <section id="drools_key_features">
+ <title>Guvnor Tools Key Features</title>
+
+ <para>The following table lists all valuable features of the <property>Guvnor
+ Tools</property>.</para>
+ <table>
+ <title>Key Functionality of Guvnor Tools</title>
+ <tgroup cols="3">
+
+ <colspec colnum="1" align="left" colwidth="1*"/>
+ <colspec colnum="2" colwidth="5*"/>
+ <colspec colnum="3" align="left" colwidth="1*"/>
+
+ <thead>
+ <row>
+ <entry>Feature</entry>
+ <entry>Benefit</entry>
+ <entry>Chapter</entry>
+ </row>
+ </thead>
+
+ <tbody>
+
+ <row>
+ <entry>
+ <para>Guvnor Repositories View</para>
+ </entry>
+ <entry>
+ <para>The purpose of the view is to enable access to Guvnor repository
+ resources in a standard tree format</para>
+ </entry>
+ <entry>
+ <link linkend="guvnor_repositories_view">Guvnor Repositories View</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Guvnor Connection Wizard</para>
+ </entry>
+ <entry>
+ <para>The wizard helps to create a connection to a Guvnor
+ repository.</para>
+ </entry>
+ <entry>
+ <link linkend="connection_wizard">Guvnor Connection Wizard</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Guvnor Resource History View</para>
+ </entry>
+ <entry>
+ <para>This view shows revisions of specific resources available in the
+ repository.</para>
+ </entry>
+ <entry>
+ <link linkend="guvnor_history_view">Guvnor Resource History View</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Resources from Guvnor Wizard</para>
+ </entry>
+ <entry>
+ <para>The wizard helps to get local copies of Guvnor repository
+ resources.</para>
+ </entry>
+ <entry>
+ <link linkend="resources_from_guvnor">Importing Guvnor Repository
+ Resources</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>A number of actions for working with files</para>
+ </entry>
+ <entry>
+ <para>The Guvnor actions (available through the <emphasis>
+ <property>Guvnor</property>
+ </emphasis> context menu on files) are provided for working with
+ files, both those associated with Guvnor repository master copies
+ and those not associated.</para>
+ </entry>
+ <entry>
+ <link linkend="actions">Actions for Local Guvnor Resources</link>
+ </entry>
+ </row>
+
+ </tbody>
+ </tgroup>
+ </table>
+ </section>
+
+ <section id="how_to_start">
+ <title>How to start with Guvnor Tools</title>
+
+ <para><property>Guvnor Tools</property> is a part of the <property>JBoss Tools</property>
+ project. Thus to get started with <property>Guvnor Tools</property>, you should have the following:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>Eclipse 3.4.x with Jboss Tools bundle of Eclipse plugins installed. How to
+ install JBoss Tools onto Eclipse you can find in the JBoss Tools Installation section.</para>
+ </listitem>
+
+ <listitem>
+ <para>JBoss Server 4.2 or higher with Guvnor repository deployed. Thus, you should
+ download <ulink
+ url="http://download.jboss.org/drools/release/5.0.0.25561.CR1/drools-5.0.0.CR1..."
+ >Guvnor CR1</ulink> and extract it to the deploy directory of the
+ server.</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Now refer to the <link linkend="functionality_overview">"Functionality
+ Overview"</link> section to find out what you can do with Guvnor and
+ Eclipse synchronisation tool.</para>
+ </section>
+
+ <section>
+ <title>Other relevant resources on the topic</title>
+
+ <itemizedlist>
+ <listitem>
+ <para>Guvnor <ulink url="http://www.jboss.org/community/wiki/Guvnor">wiki page</ulink></para>
+ </listitem>
+
+ <listitem>
+ <para>Drools on <ulink url="http://www.jboss.org/drools/">JBoss.org</ulink></para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://www.jboss.org/tools/">JBoss Tools Home Page</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">The latest
+ JBossTools/JBDS documentation builds</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://docs.jboss.org/tools/">JBossTools/JBDS
+ release documentation</ulink></para>
+ </listitem>
+ </itemizedlist>
+
+ </section>
+</chapter>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+"http://www.docbook.org/xml/4.3/docbookx.dtd"
+
+[<!ENTITY introduction SYSTEM "introduction.xml">
+<!ENTITY functionality_overview SYSTEM "functionality_overview.xml">
+<!ENTITY guvnor_preferences SYSTEM "guvnor_preferences.xml">
+<!ENTITY conclusion SYSTEM "conclusion.xml">
+
+<!ENTITY seamlink "../../seam/html_single/index.html">
+<!ENTITY aslink "../../as/html_single/index.html">
+<!ENTITY esblink "../../esb_ref_guide/html_single/index.html">
+<!ENTITY gsglink "../../GettingStartedGuide/html_single/index.html">
+<!ENTITY hibernatelink "../../hibernatetools/html_single/index.html">
+<!ENTITY jbpmlink "../../jbpm/html_single/index.html">
+<!ENTITY jsflink "../../jsf/html_single/index.html">
+<!ENTITY jsfreflink "../../jsf_tools_ref_guide/html_single/index.html">
+<!ENTITY jsftutoriallink "../../jsf_tools_tutorial/html_single/index.html">
+<!ENTITY strutsreflink "../../struts_tools_ref_guide/html_single/index.html">
+<!ENTITY strutstutoriallink "../../struts_tools_tutorial/html_single/index.html">
+
+]>
+
+<book>
+
+ <bookinfo>
+ <title>Eclipse Guvnor Tools Reference Guide</title>
+
+ <corpauthor>
+ <inlinemediaobject>
+ <imageobject role="fo">
+ <imagedata format="PNG" fileref="images/jbosstools_logo.png" />
+ </imageobject>
+ <imageobject role="html">
+ <imagedata/>
+ </imageobject>
+ </inlinemediaobject>
+ </corpauthor>
+ <author><firstname>John</firstname><surname>Graham</surname><email>jgraham(a)redhat.com</email></author>
+ <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
+
+ <copyright>
+ <year>2009</year>
+ <year>2010</year>
+ <holder>JBoss by Red Hat</holder>
+ </copyright>
+ <releaseinfo>
+ Version: 5.1.0.trunk
+ </releaseinfo>
+<abstract>
+ <title/>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/guvnor_tools_ref_gui...">PDF version</ulink>
+ </para>
+ </abstract>
+
+ </bookinfo>
+
+
+ <toc/>
+ &introduction;
+ &functionality_overview;
+ &guvnor_preferences;
+ &conclusion;
+
+</book>
Added: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master_output.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master_output.xml (rev 0)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/master_output.xml 2010-03-04 11:12:59 UTC (rev 20642)
@@ -0,0 +1,1077 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+"http://www.docbook.org/xml/4.3/docbookx.dtd"
+
+[<!ENTITY introduction SYSTEM "modules/introduction.xml">
+<!ENTITY functionality_overview SYSTEM "modules/functionality_overview.xml">
+<!ENTITY guvnor_preferences SYSTEM "modules/guvnor_preferences.xml">
+<!ENTITY conclusion SYSTEM "modules/conclusion.xml">
+
+<!ENTITY seamlink "../../seam/html_single/index.html">
+<!ENTITY aslink "../../as/html_single/index.html">
+<!ENTITY esblink "../../esb_ref_guide/html_single/index.html">
+<!ENTITY gsglink "../../GettingStartedGuide/html_single/index.html">
+<!ENTITY hibernatelink "../../hibernatetools/html_single/index.html">
+<!ENTITY jbpmlink "../../jbpm/html_single/index.html">
+<!ENTITY jsflink "../../jsf/html_single/index.html">
+<!ENTITY jsfreflink "../../jsf_tools_ref_guide/html_single/index.html">
+<!ENTITY jsftutoriallink "../../jsf_tools_tutorial/html_single/index.html">
+<!ENTITY strutsreflink "../../struts_tools_ref_guide/html_single/index.html">
+<!ENTITY strutstutoriallink "../../struts_tools_tutorial/html_single/index.html">
+
+]><book xmlns:diffmk="http://diffmk.sf.net/ns/diff">
+
+ <bookinfo>
+ <title>Eclipse Guvnor Tools Reference Guide</title>
+
+ <corpauthor>
+ <inlinemediaobject>
+ <imageobject role="fo">
+ <imagedata fileref="images/jbosstools_logo.png" format="PNG"></imagedata>
+ </imageobject>
+ <imageobject role="html">
+ <imagedata></imagedata>
+ </imageobject>
+ </inlinemediaobject>
+ </corpauthor>
+ <author><firstname>John</firstname><surname>Graham</surname><email>jgraham(a)redhat.com</email></author>
+ <author><firstname>Olga</firstname><surname>Chikvina</surname></author>
+
+ <copyright>
+ <year>2009</year>
+ <year>2010</year>
+ <holder>JBoss by Red Hat</holder>
+ </copyright>
+ <releaseinfo>
+ Version: 5.1.0.trunk
+ </releaseinfo>
+<abstract>
+ <title></title>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/en/guvnor_tools_ref_gui...">PDF version</ulink>
+ </para>
+ </abstract>
+
+ </bookinfo>
+
+
+ <toc></toc>
+
+
+<chapter id="introduction" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/guvnor_ref/en/modules/introduction.xml" xreflabel="introduction">
+ <title>Introduction</title>
+
+ <para>The purpose of this document is to describe briefly the functionality present in the
+ <property moreinfo="none">Eclipse Guvnor Tools</property> (EGT) for Drools 5. While not intended as a
+ comprehensive reference, there should be enough detail included for early adopters using
+ these tools.</para>
+
+ <para>The <property moreinfo="none">Guvnor repository</property> is not intended as a Source Code Management
+ (SCM) solution, and the <property moreinfo="none">EGT</property> are not intended to be Eclipse “team
+ provider” extensions or replacements. Rather, the Guvnor repository is a location where
+ certain artifacts (such as rules and SOA policy definitions) are controlled (“governed”) by
+ policies defined by the deployment environment. The purpose of the <property moreinfo="none">EGT</property>
+ is then to enable access to resources held by the Guvnor repository, so
+ they can be used in development. Thus, limited capabilities for reading, writing, adding,
+ and removing Guvnor repository resources are provided in the
+ <property moreinfo="none">EGT</property>.</para>
+
+ <section id="drools_key_features">
+ <title>Guvnor Tools Key Features</title>
+
+ <para>The following table lists all valuable features of the <property moreinfo="none">Guvnor
+ Tools</property>.</para>
+ <table>
+ <title>Key Functionality of Guvnor Tools</title>
+ <tgroup cols="3">
+
+ <colspec align="left" colnum="1" colwidth="1*"></colspec>
+ <colspec colnum="2" colwidth="5*"></colspec>
+ <colspec align="left" colnum="3" colwidth="1*"></colspec>
+
+ <thead>
+ <row>
+ <entry>Feature</entry>
+ <entry>Benefit</entry>
+ <entry>Chapter</entry>
+ </row>
+ </thead>
+
+ <tbody>
+
+ <row>
+ <entry>
+ <para>Guvnor Repositories View</para>
+ </entry>
+ <entry>
+ <para>The purpose of the view is to enable access to Guvnor repository
+ resources in a standard tree format</para>
+ </entry>
+ <entry>
+ <link linkend="guvnor_repositories_view">Guvnor Repositories View</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Guvnor Connection Wizard</para>
+ </entry>
+ <entry>
+ <para>The wizard helps to create a connection to a Guvnor
+ repository.</para>
+ </entry>
+ <entry>
+ <link linkend="connection_wizard">Guvnor Connection Wizard</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Guvnor Resource History View</para>
+ </entry>
+ <entry>
+ <para>This view shows revisions of specific resources available in the
+ repository.</para>
+ </entry>
+ <entry>
+ <link linkend="guvnor_history_view">Guvnor Resource History View</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>Resources from Guvnor Wizard</para>
+ </entry>
+ <entry>
+ <para>The wizard helps to get local copies of Guvnor repository
+ resources.</para>
+ </entry>
+ <entry>
+ <link linkend="resources_from_guvnor">Importing Guvnor Repository
+ Resources</link>
+ </entry>
+ </row>
+
+ <row>
+ <entry>
+ <para>A number of actions for working with files</para>
+ </entry>
+ <entry>
+ <para>The Guvnor actions (available through the <emphasis>
+ <property moreinfo="none">Guvnor</property>
+ </emphasis> context menu on files) are provided for working with
+ files, both those associated with Guvnor repository master copies
+ and those not associated.</para>
+ </entry>
+ <entry>
+ <link linkend="actions">Actions for Local Guvnor Resources</link>
+ </entry>
+ </row>
+
+ </tbody>
+ </tgroup>
+ </table>
+ </section>
+
+ <section id="how_to_start">
+ <title>How to start with Guvnor Tools</title>
+
+ <para><property moreinfo="none">Guvnor Tools</property> is a part of the <property moreinfo="none">JBoss Tools</property>
+ project. Thus to get started with <property moreinfo="none">Guvnor Tools</property>, you should have the following:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>Eclipse 3.4.x with Jboss Tools bundle of Eclipse plugins installed. How to
+ install JBoss Tools onto Eclipse you can find in the <ulink url="../../GettingStartedGuide/html_single/index.html#JBossToolsInstall">"JBoss Tools
+ Installation"</ulink> section.</para>
+ </listitem>
+
+ <listitem>
+ <para>JBoss Server 4.2 or higher with Guvnor repository deployed. Thus, you should
+ download <ulink url="http://download.jboss.org/drools/release/5.0.0.25561.CR1/drools-5.0.0.CR1...">Guvnor CR1</ulink> and extract it to the deploy directory of the
+ server.</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Now refer to the <link linkend="functionality_overview">"Functionality
+ Overview"</link> section to find out what you can do with Guvnor and
+ Eclipse synchronisation tool.</para>
+ </section>
+
+ <section>
+ <title>Other relevant resources on the topic</title>
+
+ <itemizedlist>
+ <listitem>
+ <para>Guvnor <ulink url="http://www.jboss.org/community/wiki/Guvnor">wiki page</ulink></para>
+ </listitem>
+
+ <listitem>
+ <para>Drools on <ulink url="http://www.jboss.org/drools/">JBoss.org</ulink></para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://www.jboss.org/tools/">JBoss Tools Home Page</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://download.jboss.org/jbosstools/nightly-docs/">The latest
+ JBossTools/JBDS documentation builds</ulink>
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <ulink url="http://docs.jboss.org/tools/">JBossTools/JBDS
+ release documentation</ulink></para>
+ </listitem>
+ </itemizedlist>
+
+ </section>
+</chapter>
+
+
+<chapter id="functionality_overview" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/guvnor_ref/en/modules/functionality_overview.xml" xreflabel="functionality_overview">
+ <?dbhtml filename="functionality_overview.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Functionality Overview</title>
+
+ <para>This chapter will introduce you to the <property moreinfo="none">Guvnor Repository Exploring
+ perspective</property> and give an overview on all functionality the <property moreinfo="none">Guvnor Tools</property> provides.</para>
+
+ <section id="guvnor_perspective">
+ <title>Guvnor Perspective</title>
+
+ <para>The <property moreinfo="none">Guvnor Repository Exploring perspective</property> contains two views
+ supplied by <property moreinfo="none">EGT</property> – <property moreinfo="none">Repository Explorer</property> and
+ <property moreinfo="none">Version History</property>, that will be the center of most interaction
+ with Guvnor, and Eclipse standard views such as <property moreinfo="none">Properties</property> and
+ <property moreinfo="none">Resource Navigator</property> that are also useful.</para>
+
+ <para>While each of these views can be opened and positioned independently within an Eclipse
+ workbench, the <property moreinfo="none">Guvnor perspective</property> provides a convenient method of
+ getting a suggested layout. In the Eclipse workbench menu, choose <emphasis>
+ <property moreinfo="none">Window > Open Perspective > Other</property>
+ </emphasis> to get the perspective list:</para>
+
+ <figure float="0">
+ <title>Enabling the Guvnor Repository Perspective</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/open_guvnor_perspectine.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>And then choose <emphasis>
+ <property moreinfo="none">Guvnor Repository Exploring</property>.</emphasis> This opens the
+ <property moreinfo="none">Guvnor perspective</property>.</para>
+ </section>
+
+ <section id="connection_wizard">
+ <title>Guvnor Connection Wizard</title>
+
+ <para>After opening the <property moreinfo="none">Guvnor perspective</property>, the first task is to make a
+ connection to a Guvnor repository. This is handled by the <property moreinfo="none">Guvnor Connection
+ wizard</property>. This wizard appears in a number of places within the
+ <property moreinfo="none">EGT</property> (as detailed below), but in this section we will cover only
+ the two most basic entry points.</para>
+
+ <para>The <property moreinfo="none">Guvnor Connection wizard</property> can be started in the following
+ ways:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>using the Eclipse menu <emphasis>
+ <property moreinfo="none">File > New > Other > Guvnor > Guvnor
+ repository location</property>
+ </emphasis></para>
+
+ <figure float="0">
+ <title>New Guvnor Repository Location</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/start_guvnor_connection1.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </listitem>
+
+ <listitem>
+ <para>in the <property moreinfo="none">Guvnor Repositories view</property> using the drop-down menu</para>
+
+ <figure float="0">
+ <title>Adding New Guvnor Connection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/start_guvnor_connection2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </listitem>
+
+ <listitem>
+ <para>using the menu button
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_connection_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> )
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Choosing either of these will start the <property moreinfo="none">Guvnor Connection
+ wizard</property>.</para>
+
+ <figure float="0" id="guvnor_connection_wizard">
+ <title>Guvnor Connection Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_connection_wizard.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Default values appear in the <emphasis>
+ <property moreinfo="none">Location</property>,</emphasis>
+ <emphasis>
+ <property moreinfo="none">Port</property>,</emphasis> and <emphasis>
+ <property moreinfo="none">Repository</property>
+ </emphasis> fields (See the <link linkend="guvnor_preferences">“Guvnor Preferences”</link> section below for details about how to
+ change these default values.) Of course, any of these fields can be edited by typing in
+ the corresponding text box. Drag-and-drop or paste into the <emphasis>
+ <property moreinfo="none">Location</property>
+ </emphasis> field of a typical Guvnor repository URL such as:</para>
+
+ <para>
+ <emphasis>
+ <property moreinfo="none">http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/webdav</property>
+ </emphasis>
+ </para>
+
+ <para>Results in the URL being parsed into the respective fields as well. The authentication
+ information (user name and password) can optionally be stored in the Eclipse
+ workbench's key-ring file based on the selection of <emphasis>
+ <property moreinfo="none">Save user name and password</property>.</emphasis></para>
+
+ <note>
+ <title>Note:</title>
+ <para>If the authentication information is not stored in the key-ring, then the
+ <property moreinfo="none">EGT</property> uses a session authentication, what means that the
+ credentials supplied are used only for the lifetime of the Eclipse workbench
+ instance.</para>
+ </note>
+
+ <para>If authentication information is not stored in the key-ring or the authentication
+ information (key-ring or session) is not valid, the <property moreinfo="none">EGT</property> will prompt
+ for authentication information when it has to access the Guvnor repository.</para>
+
+ <para>If authentication fails, the <property moreinfo="none">EGT</property> will retry once and then issue
+ an authentication failure error.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para>If an authentication failure error occurs, you can retry the same operation and
+ supply different authentication information.</para>
+ </tip>
+
+ <para>Note that the <property moreinfo="none">EGT</property> calls the Guvnor repository at various times,
+ such as when determining if resource updates are available. Thus if you use session
+ authentication, the authentication dialog will appear at different times during the
+ Eclipse workbench session, depending on what actions you take. For ease of use, we
+ recommend saving the authentication information in the Eclipse key-ring.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>The Eclipse key-ring file is distinct from key-ring files found in some platforms
+ such as Mac OS X and many forms of Linux. Thus, sometimes if you access a Guvnor
+ repository outside the <property moreinfo="none">EGT</property>, the key-ring files might become
+ unsynchronized and you will be unexpectedly prompted for authentication in Eclipse.
+ This is nuisance, but your usual credentials should apply in this case.</para>
+ </note>
+ </section>
+
+ <section id="guvnor_repositories_view">
+ <title>Guvnor Repositories View</title>
+
+ <para>The <property moreinfo="none">Guvnor Repositories view</property> contains tree structures for Guvnor
+ repository contents.</para>
+
+ <figure float="0">
+ <title>Guvnor Repositories View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnor_repository.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>You can perform the following actions under the resources in the
+ <property moreinfo="none">Guvnor Repositories view</property>:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>create a new Guvnor repository connection. How to do this is describe above in the <link linkend="connection_wizard">"Guvnor Connection Wizard"</link> section.</para>
+ </listitem>
+
+ <listitem>
+ <para>remove a Guvnor repository connection. Use the Delete button
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/delete_connection_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> ) in the tool-bar or the <emphasis>
+ <property moreinfo="none">Delete</property></emphasis> option in the context menu to remove a repository connection.</para>
+ </listitem>
+
+ <listitem>
+ <para>refresh Guvnor repository resorces. Use the <emphasis>
+ <property moreinfo="none">Refresh</property></emphasis> context menu item to reload a tree content for the selected node.</para>
+ </listitem>
+
+ <listitem>
+ <para>make use of "drill-into" functionality. It's represented by a number of tool-bar/context menu items such as <emphasis><property moreinfo="none">Go Home</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_home_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> ), <emphasis><property moreinfo="none">Go Back</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_back_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> ) and <emphasis>
+ <property moreinfo="none">Go Into</property></emphasis>
+ ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_into_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> ).</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Drill-down is useful when working with deeply nested tree structures and when you wish to concentrate on only branch of the tree. For example, drilling into the <emphasis>
+ <property moreinfo="none">"defaultPackage"</property></emphasis> node changes the tree view to:</para>
+
+ <figure float="0">
+ <title>Going Into the <emphasis>"defaultPackage"</emphasis></title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_into_defaultPackage.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Clicking on the Go Home button ( <inlinemediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/go_home_button.png"></imagedata>
+ </imageobject>
+ </inlinemediaobject> ) or selecting <emphasis>
+ <property moreinfo="none">Go Home</property></emphasis> in the context menu returns the tree to the top-level structure shown in the previous picture above.
+ </para>
+
+ <para>There are a number of operations that can be performed on Guvnor repository files. Selecting a file in
+the Guvnor repository causes the Eclipse <property moreinfo="none">Properties view</property> to update with details about that file:
+</para>
+
+ <figure float="0">
+ <title>Guvnor Repository Files Properties</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/repository_files_properties.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para></para>
+ </section>
+
+ <section id="local_copies">
+ <title>Local Copies of Guvnor Files</title>
+
+ <para>As mentioned in the <link linkend="introduction">"Introduction"</link>, the main purpose
+ of the <property moreinfo="none">EGT</property> is to allow development using resources held in a Guvnor
+ repository. There are two method of getting local copies of Guvnor repository
+ resources:</para>
+
+ <orderedlist continuation="restarts" inheritnum="ignore">
+ <listitem>
+ <para>Drag-and-drop from the <property moreinfo="none">Guvnor Repositories view</property></para>
+ </listitem>
+ <listitem>
+ <para>Using the <link linkend="resources_from_guvnor">Import from Guvnor
+ wizard</link>, as described further in this document</para>
+ </listitem>
+ </orderedlist>
+
+ <para>When local copies of Guvnor repository files are created, the <property moreinfo="none">EGT</property>
+ sets an association between the local copy and the master file in the repository. This
+ information is kept in the (normally) hidden <emphasis>
+ <property moreinfo="none">.guvnorinfo</property>
+ </emphasis> folder in the local project and, like all metadata, should not be changed by
+ end users.</para>
+
+ <figure float="0">
+ <title>.guvnorinfo metadata</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/guvnorinfo.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The association allows for operations such as update and commit in
+ synchronization with the master copy held in the Guvnor repository.</para>
+
+ <para>The <property moreinfo="none">EGT</property> decorates local resources associated with Guvnor
+ repository master copies. This decoration appears in Eclipse views conforming to the
+ Eclipse Common Navigator framework, such as the Eclipse <property moreinfo="none">Resource
+ Navigator</property> and the Java <property moreinfo="none">Package Explorer</property>. On the image
+ above you can see the <emphasis>
+ <property moreinfo="none">Dummy rule.drl</property></emphasis> file with the decoration in the <property moreinfo="none">Resource Navigator</property>. The Guvnor icon decorator is on the top right of the file image, and the Guvnor
+ revision details are appended to the file name. (The presence/location of these can be
+ changed the <link linkend="resource_decoration_preferences">Guvnor
+ Preferences</link>.)</para>
+
+ <para>Here we see that, <emphasis><property moreinfo="none">Dummy role.drl</property></emphasis> is associated with a Guvnor repository
+ resource and the local copy is based on revision 0, with a <code>02-10-2008, 4:21:53</code> date/time
+ stamp. The file <emphasis><property moreinfo="none">Sample.drl</property>,</emphasis> however, is not associated with a Guvnor repository
+ file. Further details about the association can be found in the standard Eclipse
+ properties page, accessed via the <emphasis><property moreinfo="none">Properties</property></emphasis> option in the context menu:</para>
+
+ <figure float="0">
+ <title>Association Details</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/association_details.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The <property moreinfo="none">EGT</property> contributes a property page to the standard Eclipse
+ properties dialog, the contents of which are shown above. It displays the specific Guvnor
+ repository, the location within the repository, the version (date/time stamp) and
+ the revision number.</para>
+ </section>
+
+ <section id="actions">
+ <title>Actions for Local Guvnor Resources</title>
+
+ <para>The <property moreinfo="none">EGT</property> provides a number of actions (available through the
+ <emphasis><property moreinfo="none">Guvnor</property></emphasis> context menu on files) for working with files, both those associated with
+ Guvnor repository master copies and those not associated. The actions are:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>
+ <link linkend="update_action">Update</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="add_action">Add</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="commit_action">Commit</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="show_history_action">Show History</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="compare_with_version">Compare with Version</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="switch_to_version">Switch to Version</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="delete_action">Delete</link>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <link linkend="disconnect_action">Disconnect</link>
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Each of these actions is described below.</para>
+
+ <section id="update_action">
+ <title>Update Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Update</property>
+ </emphasis> action is available for one or more Guvnor resources that are not in
+ synchronization with the Guvnor repository master copies. These resources would not
+ be in synchronization because either/both</para>
+
+ <orderedlist continuation="restarts" inheritnum="ignore">
+ <listitem><para>There are local changes to these
+ resources</para></listitem>
+ <listitem><para>The master copies have been changed in the Guvnor repository</para></listitem>
+ </orderedlist>
+
+ <para>Performing the <emphasis>
+ <property moreinfo="none">Update</property>
+ </emphasis> action replaces the local file contents with the current contents from
+ the Guvnor repository master copies (equivalent to <emphasis>
+ <link linkend="switch_to_version">Switch to version</link>
+ </emphasis> for the latest version).</para>
+ </section>
+
+ <section id="add_action">
+ <title>Add Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Add</property>
+ </emphasis> action is available for one or more local files that are not associated
+ with a Guvnor repository master copy. Choosing the <emphasis>
+ <property moreinfo="none">Add</property>
+ </emphasis> action launches the <property moreinfo="none">Add to Guvnor wizard</property>:</para>
+
+ <figure float="0">
+ <title>Add to Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The first page of the wizard asks for the selection of the target Guvnor
+ repository and gives the choice to create a new Guvnor repository connection (in
+ which case the second page is the same as the <link linkend="guvnor_connection_wizard">Guvnor Connection wizard</link>). Once the target Guvnor repository is chosen,
+ the wizard then asks for the folder location to add the selection files:</para>
+
+ <figure float="0">
+ <title>Selecting a Target Folder</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/select_target_folder.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Here the <emphasis>
+ <property moreinfo="none">"defaultPackage"</property></emphasis> folder is selected as the destination
+ location.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>Note that the <emphasis>
+ <property moreinfo="none">"snapshot"</property></emphasis> folder in the Guvnor repository is read-only for
+ <property moreinfo="none">EGT</property>, and hence not visible as a candidate location in
+ this wizard. The Guvnor repository web administration tools must be used to add
+ snapshot content.</para>
+ </note>
+
+ <para>Clicking on <emphasis>
+ <property moreinfo="none">Finish</property>
+ </emphasis> adds the selected files to the Guvnor repository and creates an
+ association between the local and Guvnor repository files.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>Note that the wizard will not allow for overwrite of existing Guvnor
+ repository files. Another target location must be chosen.</para>
+ </note>
+ </section>
+
+ <section id="commit_action">
+ <title>Commit Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Commit</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files
+ that have local changes. The <emphasis>
+ <property moreinfo="none">Commit</property>
+ </emphasis> action will write the local changes back to the associated Guvnor
+ repository files and update the association for the new revision created.</para>
+
+ <para>If a local change is based on an older revision of a file that is currently in the
+ Guvnor repository (for example, someone else changed the same file), then the <emphasis>
+ <property moreinfo="none">Commit</property>
+ </emphasis> action will<figure float="0">
+ <title>Add to Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure> ask whether you wish to overwrite the current version in the
+ Guvnor repository with the local content. When such conflicts occur, however, you
+ should use the Eclipse Guvnor version tools, along with Eclipse standard tools, to
+ determine the differences and merge content based on the current version in the
+ Guvnor repository.</para>
+ </section>
+
+ <section id="show_history_action">
+ <title>Show History Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Show History</property>
+ </emphasis> action is enable for one Guvnor repository associated file and causes
+ the <link linkend="guvnor_history_view">Guvnor Resource History view</link> to be
+ populated with revision history for the selected file.</para>
+ </section>
+
+ <section id="compare_with_version">
+ <title>Compare with Version Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Compare with Version</property>
+ </emphasis> action is enabled for one Guvnor repository associated file. This action
+ first opens a wizard asking for the version for comparison (with the local file
+ contents):</para>
+
+ <figure float="0">
+ <title>Compare with Version Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the revision is selected, the action opens the Eclipse <property moreinfo="none">Compare
+ editor</property> (read-only):</para>
+ <figure float="0">
+ <title>Eclipse Compare Editor</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>This editor uses Eclipse-standard comparison techniques to show the differences in
+ the two versions. In cases where there are no differences, the editor will not open,
+ rather a dialog saying that there are no differences will appear.</para>
+ <figure float="0">
+ <title>Alert Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+
+ <section id="switch_to_version">
+ <title>Switch to Version Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Switch to Version</property>
+ </emphasis> action is enabled for one Guvnor repository associated file.</para>
+ <para>First the <emphasis>
+ <property moreinfo="none">Switch to Version</property>
+ </emphasis> action prompts for selection of version:</para>
+
+ <figure float="0">
+ <title>Select Version Window</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/compare_with_version.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the version is selected, the <emphasis>
+ <property moreinfo="none">Switch to Version</property>
+ </emphasis> action replaces the local file contents with those from the revision
+ selected.</para>
+ </section>
+
+ <section id="delete_action">
+ <title>Delete Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Delete</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files.
+ After confirmation via a dialog, the <emphasis>
+ <property moreinfo="none">Delete</property>
+ </emphasis> action removes the files in the Guvnor repository and deletes local
+ metadata for the Guvnor repository association.</para>
+
+ <figure float="0">
+ <title>Comfirm Delete Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/confirm_delete.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+
+ <section id="disconnect_action">
+ <title>Disconnect Action</title>
+
+ <para>The <emphasis>
+ <property moreinfo="none">Disconnect</property>
+ </emphasis> action is enabled for one or more Guvnor repository associated files,
+ and removes local metadata for the Guvnor repository association.</para>
+ </section>
+ </section>
+
+ <section id="guvnor_history_view">
+ <title>Guvnor Resource History View</title>
+
+ <para>The <property moreinfo="none">Guvnor Resource History view</property> should details about revision
+ history for selected files, both local and those in Guvnor repositories. The initial
+ state of this view is shown on the figure below.</para>
+
+ <figure float="0">
+ <title>Initial State of the Guvnor Resource History View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The <property moreinfo="none">Guvnor Resource History view</property> is populated by <emphasis>
+ <property moreinfo="none">Show History</property>
+ </emphasis> actions in either the local <emphasis>
+ <property moreinfo="none">Guvnor</property></emphasis> context menu or in the context menu for
+ a Guvnor repository file in the <link linkend="guvnor_repositories_view">Guvnor
+ Repositories view</link>. Once this action is performed, the <property moreinfo="none">Guvnor
+ Resource History view</property> updates to show the revision history:</para>
+
+ <figure float="0">
+ <title>IGuvnor Resource History View</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Here we see that the file <emphasis>
+ <property moreinfo="none">test.txt</property>
+ </emphasis> has three revisions. Double clicking on a revision row (or the context menu <emphasis>
+ <property moreinfo="none">Open (Read only)</property>)</emphasis> opens an Eclipse read-only editor
+ with the revision contents.</para>
+
+ <figure float="0">
+ <title>Eclipse Read-only Editor with the Revision Contents</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_history_view3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <note>
+ <title>Note:</title>
+ <para>You can also use the <emphasis>
+ <property moreinfo="none">Save As...</property>
+ </emphasis> option when a file is open in a read-only editor to save a local
+ writable copy of the contents. Doing so, however, will not associate the file
+ created with its Guvnor source.</para>
+ </note>
+
+ </section>
+
+ <section id="resources_from_guvnor">
+ <title>Importing Guvnor Repository Resources</title>
+
+ <para>In addition to the single file drag-and-drop from the <property moreinfo="none">Guvnor Repositories
+ view</property>, the <property moreinfo="none">EGT</property> also includes a wizard for copying one
+ or more files from a Guvnor repository to the local workspace (and setting the
+ association with the Guvnor repository). This wizard is available from the <emphasis>
+ <property moreinfo="none">File > Import > Guvnor > Resource from
+ Guvnor</property>
+ </emphasis> and the <emphasis>
+ <property moreinfo="none">File > New > Other > Guvnor > Resource from
+ Guvnor</property>
+ </emphasis> menu items.</para>
+ <note>
+ <title>Note:</title>
+
+ <para>Note that the wizard is identical but appears in both locations to accommodate
+ users who tend to view this functionality as being in either category.</para>
+ </note>
+
+ <para>The first page of the wizard asks for the selection of the source Guvnor repository
+ and gives the choice to create a new Guvnor repository connection (in which case the
+ second page is the same as the <link linkend="guvnor_connection_wizard">Guvnor Connection wizard</link>).</para>
+
+ <figure float="0">
+ <title>Resource from Guvnor Wizard</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/add_toGuvnor_wizard.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Once the source Guvnor repository is chosen, the wizard prompts for resource selection:</para>
+
+ <figure float="0">
+ <title>Resource Selection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Finally, the target location in the local workspace should be chosen:</para>
+ <figure float="0">
+ <title>Choosing the Target Location</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor2.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>On completion the wizard copies the selected files from the Guvnor repository to the local workspace.
+ If a file with the same name already exists in the destination, the wizard uses the Eclipse standard
+ "prompt for rename" dialog:</para>
+
+ <figure float="0">
+ <title>Prompt for Rename Dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/functionality_overview/resource_from_guvnor3.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ </section>
+</chapter>
+
+
+<chapter id="guvnor_preferences" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/guvnor_ref/en/modules/guvnor_preferences.xml" xreflabel="guvnor_preferences">
+ <?dbhtml filename="guvnor_preferences.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Guvnor Preferences</title>
+
+ <para>The <property moreinfo="none">EGT</property> provides a preference page in the <emphasis>
+ <property moreinfo="none">Guvnor</property>
+ </emphasis> category:</para>
+
+ <figure float="0">
+ <title>Resource Selection</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/guvnor_preferences/guvnor_preferences.png"></imagedata>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The preferences cover two categories:</para>
+ <itemizedlist>
+ <listitem><para>Guvnor repository connections</para></listitem>
+
+ <listitem><para>Local Guvnor
+ repository resource decorations.</para></listitem>
+ </itemizedlist>
+
+ <section id="repo_connection_preferences">
+ <title>Guvnor Repository Connection Preferences</title>
+ <para>There are two preferences that can be set for Guvnor repository connections, that are
+ used when creating new connections:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>The first is a default Guvnor repository URL template, which can make it
+ easier to create multiple similar connections by simply changing part of the
+ field, such as the host name.</para>
+ </listitem>
+ <listitem>
+ <para>The second is whether saving of authentication information in the Eclipse
+ platform key-ring should be enabled by default.</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>As with the Guvnor repository URL template, actually whether to save a specific
+ instance of authentication information in the Eclipse platform key-ring can be
+ determined when actually creating the connection. That is, both of these preferences are
+ simply convenience values set to reasonable defaults.</para>
+ </section>
+
+ <section id="resource_decoration_preferences">
+ <title>Local Guvnor Repository Resource Decoration Preferences</title>
+
+ <para>The second category of preferences provided by the <property moreinfo="none">EGT</property> deals with how the decoration of
+ local resources associated with Guvnor repository resources is presented. Since the
+ Guvnor repository is not a substitute for a SCM, and since SCM tools in Eclipse tend to
+ decorate local resources, it is useful to be able to control just how the <property moreinfo="none">EGT</property> decorate
+ its local resources to avoid messy conflicts with SCM packages.</para>
+
+ <para>In the <emphasis>
+ <property moreinfo="none">File Decoration</property></emphasis>
+ section of the preference page, you can choose the location (Top right, Top left, Bottom right,
+ Bottom left) of the decoration icon, or you can choose not to display it. In
+ the <emphasis>
+ <property moreinfo="none">Text</property></emphasis> section, you can format the Guvnor metadata that is appended to the file
+ names:</para>
+ <itemizedlist>
+ <listitem>
+ <para>Whether to show an indicator (>) when the local file has changes not committed back to the
+ Guvnor repository</para>
+ </listitem>
+ <listitem>
+ <para>Whether to show the revision number</para>
+ </listitem>
+ <listitem>
+ <para>Whether to show the date/time stamp</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>Any changes to these preferences take effect immediately upon clicking the <emphasis>
+ <property moreinfo="none">Apply</property></emphasis> and then <emphasis>
+ <property moreinfo="none">Ok</property></emphasis> buttons.</para>
+ </section>
+</chapter>
+
+
+<chapter id="conclusion" xml:base="file:///home/vchukhutsina/repos/ochik_jboss/drools/docs/guvnor_ref/en/modules/conclusion.xml" xreflabel="conclusion">
+ <?dbhtml filename="conclusion.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss Tools</keyword>
+ <keyword>Eclipse Guvnor Tools</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Conclusion</title>
+
+ <para>As stated at the beginning of this document, the key goal of the <property moreinfo="none">EGT</property>
+ is to provide a way of interacting with Guvnor repository resources in a local Eclipse
+ workspace. While clearly there is a lot more that could be done, and no doubt there will be
+ aspects of the current tooling that require revision going forward, we feel that the current
+ state of the <property moreinfo="none">EGT</property> is sufficient for the major use cases.</para>
+
+ <para>If you have some questions, comments or suggestions on the topic, please feel free to ask in the
+ <ulink url="http://www.jboss.org/index.html?module=bb&op=viewforum&f=201">Jboss Tools Forum</ulink>.</para>
+</chapter>
+
+
+</book>
14 years, 10 months
JBoss Tools SVN: r20641 - trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action.
by jbosstools-commits@lists.jboss.org
Author: dazarov
Date: 2010-03-04 06:11:03 -0500 (Thu, 04 Mar 2010)
New Revision: 20641
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/AddTLDMarkerResolution.java
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/JSPProblemMarkerResolutionGenerator.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-4876
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/AddTLDMarkerResolution.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/AddTLDMarkerResolution.java 2010-03-04 11:00:31 UTC (rev 20640)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/AddTLDMarkerResolution.java 2010-03-04 11:11:03 UTC (rev 20641)
@@ -16,8 +16,10 @@
import org.eclipse.core.resources.IMarker;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.text.IDocument;
-import org.eclipse.ui.IMarkerResolution;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.ui.IMarkerResolution2;
import org.eclipse.ui.part.FileEditorInput;
import org.eclipse.ui.texteditor.DocumentProviderRegistry;
import org.eclipse.ui.texteditor.IDocumentProvider;
@@ -31,7 +33,7 @@
* @author Daniel Azarov
*
*/
-public class AddTLDMarkerResolution implements IMarkerResolution{
+public class AddTLDMarkerResolution implements IMarkerResolution2{
private IFile file;
private Properties properties;
@@ -63,4 +65,12 @@
WebUiPlugin.getPluginLog().logError(ex);
}
}
+
+ public String getDescription() {
+ return Messages.AddTLDMarkerResolution_Name;
+ }
+
+ public Image getImage() {
+ return ImageDescriptor.createFromFile(AddTLDMarkerResolution.class, "images/xstudio/editors/taglibs_file.gif").createImage(); //$NON-NLS-1$
+ }
}
\ No newline at end of file
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/JSPProblemMarkerResolutionGenerator.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/JSPProblemMarkerResolutionGenerator.java 2010-03-04 11:00:31 UTC (rev 20640)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/action/JSPProblemMarkerResolutionGenerator.java 2010-03-04 11:11:03 UTC (rev 20641)
@@ -23,6 +23,7 @@
import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.ui.IMarkerResolution;
import org.eclipse.ui.IMarkerResolutionGenerator;
+import org.eclipse.ui.IMarkerResolutionGenerator2;
import org.eclipse.ui.part.FileEditorInput;
import org.eclipse.ui.texteditor.DocumentProviderRegistry;
import org.eclipse.ui.texteditor.IDocumentProvider;
@@ -37,7 +38,7 @@
* @author Daniel Azarov
*
*/
-public class JSPProblemMarkerResolutionGenerator implements IMarkerResolutionGenerator {
+public class JSPProblemMarkerResolutionGenerator implements IMarkerResolutionGenerator2 {
public static HashMap<String, String> libs = new HashMap<String, String>();
static{
@@ -61,7 +62,6 @@
new AddTLDMarkerResolution(file, properties)
};
}
-
}catch(CoreException ex){
WebUiPlugin.getPluginLog().logError(ex);
}
@@ -142,4 +142,14 @@
return prefix;
}
+
+ public boolean hasResolutions(IMarker marker) {
+ try{
+ if(isOurCase(marker))
+ return true;
+ }catch(CoreException ex){
+ WebUiPlugin.getPluginLog().logError(ex);
+ }
+ return false;
+ }
}
\ No newline at end of file
14 years, 10 months
JBoss Tools SVN: r20640 - branches/jbosstools-3.1.x/drools/docs/guvnor_ref.
by jbosstools-commits@lists.jboss.org
Author: ochikvina
Date: 2010-03-04 06:00:31 -0500 (Thu, 04 Mar 2010)
New Revision: 20640
Added:
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/en-US/
Modified:
branches/jbosstools-3.1.x/drools/docs/guvnor_ref/pom.xml
Log:
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:9pt;font-family:Sans Serif">
<p>https://jira.jboss.org/jira/browse/JBDS-1107 -Updated docs source files here with the ones for JBDS 3.0.0 GA release. </p>
<p></p>
</body></html>
Modified: branches/jbosstools-3.1.x/drools/docs/guvnor_ref/pom.xml
===================================================================
--- branches/jbosstools-3.1.x/drools/docs/guvnor_ref/pom.xml 2010-03-04 10:56:34 UTC (rev 20639)
+++ branches/jbosstools-3.1.x/drools/docs/guvnor_ref/pom.xml 2010-03-04 11:00:31 UTC (rev 20640)
@@ -94,9 +94,9 @@
<configuration>
<sourceDocumentName>master.xml</sourceDocumentName>
- <sourceDirectory>${pom.basedir}/en</sourceDirectory>
+ <sourceDirectory>${pom.basedir}/en-US</sourceDirectory>
<imageResource>
- <directory>${pom.basedir}/en</directory>
+ <directory>${pom.basedir}/en-US</directory>
<includes>
<include>images/**/*</include>
</includes>
14 years, 10 months