Author: steveh
Date: Tue Nov 9 11:50:15 2004
New Revision: 57085
Added:
incubator/beehive/site/build/site/pageflow/sample_netui-blank.html
(contents, props changed)
incubator/beehive/site/src/documentation/content/xdocs/pageflow/sample_netui-blank.xml
(contents, props changed)
Modified:
incubator/beehive/site/build/site/Controls.html
incubator/beehive/site/build/site/contributors.html
incubator/beehive/site/build/site/controls/sample_controls-blank.html
incubator/beehive/site/build/site/controls/sample_controls-db.html
incubator/beehive/site/build/site/controls/tutorial_controls.html
incubator/beehive/site/build/site/downloads.html
incubator/beehive/site/build/site/faq.html
incubator/beehive/site/build/site/index.html
incubator/beehive/site/build/site/jpetstore.html
incubator/beehive/site/build/site/license.html
incubator/beehive/site/build/site/mailinglists.html
incubator/beehive/site/build/site/pageflow/guide.html
incubator/beehive/site/build/site/pageflow/tutorial_pageflow.html
incubator/beehive/site/build/site/reference.html
incubator/beehive/site/build/site/webservices.html
incubator/beehive/site/build/site/wsm/sample_AddressBook.html
incubator/beehive/site/build/site/wsm/sample_Dashboard.html
incubator/beehive/site/build/site/wsm/sample_wsm-blank.html
incubator/beehive/site/build/site/wsm/tutorial_wsm.html
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-blank.xml
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-db.xml
incubator/beehive/site/src/documentation/content/xdocs/site.xml
incubator/beehive/site/src/documentation/content/xdocs/wsm/sample_wsm-blank.xml
incubator/beehive/site/src/documentation/content/xdocs/wsm/tutorial_wsm.xml
Log:
Adding topics on the "blank" samples/templates.
Modified: incubator/beehive/site/build/site/Controls.html
==============================================================================
--- incubator/beehive/site/build/site/Controls.html (original)
+++ incubator/beehive/site/build/site/Controls.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/contributors.html
==============================================================================
--- incubator/beehive/site/build/site/contributors.html (original)
+++ incubator/beehive/site/build/site/contributors.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/controls/sample_controls-blank.html
==============================================================================
--- incubator/beehive/site/build/site/controls/sample_controls-blank.html
(original)
+++ incubator/beehive/site/build/site/controls/sample_controls-blank.html
Tue Nov 9 11:50:15 2004
@@ -2,7 +2,7 @@
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>"Blank" Control Sample</title>
+<title>Control Project Sample</title>
<link type="text/css" href="../skin/page.css" rel="stylesheet">
</head>
<body text="#000000" bgcolor="#FFFFFF">
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<span class="sel"><font color="#ffcc00">Control Project</font></span>
</li>
@@ -258,26 +262,26 @@
<table class="title" summary="">
<tr>
<td valign="middle">
-<h1>"Blank" Control Sample</h1>
+<h1>Control Project Sample</h1>
</td>
</tr>
</table>
<ul class="minitoc">
<li>
-<a href="#intro">Distributable Control Projects</a>
+<a href="#intro">The Control Application Template</a>
</li>
-<li></li>
</ul>
-
+
<a name="N1000C"></a><a name="intro"></a>
-<h3>Distributable Control Projects</h3>
+<h3>The Control Application Template</h3>
<div style="margin-left: 0 ; border: 2px">
-<p>"Mentioning the "control project" model for using controls (perhaps as a
2nd controls tutorial?) -- ie, using the controls-blank template to create a
controls JAR that is then importable in multiple webapps (WEB-INF/lib), and
using this to help isolate business logic in controls from presentation logic
in the webapp proper." </p>
+<p>Use the "blank" Control sample (located at <span
class="codefrag">BEEHIVE_HOME/samples/controls-blank</span>) is a template for
building your own Control projects.
+
+</p>
+<p>The template contains a basic 'Hello World' control to get you started.
Control projects can be archived in a JAR file and then imported into multiple
applications. Simple import the JAR archive into the application's WEB-INF/lib
directory. </p>
</div>
-
-<a name="N10016"></a>
-<h3></h3>
-<div style="margin-left: 0 ; border: 2px"></div>
+
+
<div class="attribution"></div>
</div>
Modified: incubator/beehive/site/build/site/controls/sample_controls-db.html
==============================================================================
--- incubator/beehive/site/build/site/controls/sample_controls-db.html
(original)
+++ incubator/beehive/site/build/site/controls/sample_controls-db.html Tue Nov
9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
@@ -279,8 +283,88 @@
<a name="N1000C"></a><a
name="Control+Programming%3A+Simplifying+Access+to+Resources"></a>
<h3>Control Programming: Simplifying Access to Resources</h3>
<div style="margin-left: 0 ; border: 2px">
-<p>Control Programming...simplifying access to a resource, in this case a
database.</p>
-<a name="N10015"></a><a name="Structure+of+the+Database+Control"></a>
+<p>Control Programming...simplifying access to a resource, in this case a
database.
+
+ <!-- From Hoi Lam's email:
+ A Database control makes it easy to access a relational database from
your Java code using SQL commands. The Database control handles the work of
connecting to the database, so you don’t have to understand JDBC to work with
a database.
+
+All Database controls are subclassed from the DatabaseControl interface. The
interface defines methods that Database control instances can call from an
application.
+
+The methods that you add to a Database control execute SQL commands against
the database. You can send any SQL command to the database via the Database
control, so that you can retrieve data, perform operations like inserts and
updates.
+
+A method on a Database control always has an associated SQL statement, which
executes against the database when the method is called. The method’s @SQL
annotation describes the method’s SQL statement. The method’s SQL
statement may include substitution parameters. These parameters are replaced at
runtime with the values that were passed to the method. The names of the
substitution parameters in the SQL statement must match those in the method
signature, so that the Database control knows which parameter to replace with
which value.
+
+The following example Database control method illustrates using parameter
substitution in Database control methods:
+
+ @SQL(statement="INSERT INTO EMPLOYEE " +
+ "(id, fName, lName, title) " +
+ "VALUES ({emp.id}, {emp.fName}, {emp.lName}, {emp.title})")
+ public void insertEmployee(Employee emp) throws SQLException;
+
+In the example above, the SQL statement includes the substitution {emp.id},
{emp.fName}, ... These map to the various class variables of the "emp"
parameter in the insertEmployee method. When the method is invoked, the values
of any referenced parameters are substituted in the SQL statement before it is
executed. Note that parameter substitution is case sensitive, so parameters
mentioned in substitutions must exactly match the spelling and case of the
parameters to the method.
+
+The return type of the database operation is determined by the return type of
the Java method. The Database control attempts to format the results in
whatever type you have specified for the method to return. A method of a
Database control can return a single value, a single row, or multiple rows.
+
+When your method returns a single value, its return type must be compatible
with the value returned from the query. The following example looks up an
employee's title.
+
+ @SQL(statement="SELECT title FROM EMPLOYEE WHERE id={id}")
+ public String getEmployeeTitle(int id) throws SQLException;
+
+In this example, the title field is of type VARCHAR, so the return value is
declared as String.
+
+When your method returns a single row with multiple fields, its return type
can be a user-defined object or a java.util.HashMap object. When the return
type is a user-defined object, it must contain members with names that match
the names of the columns that will be returned by the query. Because database
column names are case-insensitive, the matching names are case-insensitive. The
class may also contain other members, members not matching any column names
will not be set. The following example declares an Employee class with members
corresponding to fields in the Employee table. The findEmployee method returns
an object of type Employee:
+
+ @SQL(statement="SELECT * FROM EMPLOYEE WHERE id={id}")
+ public Employee findEmployee(int id) throws SQLException;
+
+ public class Employee
+ {
+ public int id;
+ public String fName;
+ public String lName;
+ public String title;
+ }
+
+When your method returns multiple rows from the database, its return type can
be an array, a java.util.Iterator, or a java.sql.ResultSet.
+When you want to return an Iterator object, you must specify the
iteratorElementType element to the @SQL annotation to indicate the underlying
type that the Iterator will contain. The following example returns a iterator
of all employees sorted by their last names.
+
+ @SQL(statement="SELECT * FROM EMPLOYEE ORDER BY lName",
iteratorElementType=Employee.class, maxRows=500)
+ public Iterator getEmployeesSortedByLastName() throws SQLException;
+
+You can limit the number of rows returned by setting the maxRows element of
the @SQL annotation. This element can protect you from very large resultsets
that may be returned by very general queries. The default value of maxRow is
1024.
+
+The Database Control defines two annotations: SQL and ConnectionDataSource.
+
+The SQL Annotation specifies the SQL statement and associated attributes that
correspond to a method in a Database control.
+
+ public @interface SQL
+ {
+ String statement() default "";
+ int maxRows() default MAXROWS_ALL;
+ @AnnotationMemberTypes.Optional
+ Class iteratorElementType() default UndefinedIteratorType.class;
+ }
+
+The "statement" element is required. It specifies the SQL (Structured Query
Language) statement that will be executed when the associated Database control
method is invoked. The statement may contain substitutions of the form
{varName}, where paramName is a parameter of the Database control method (or a
member accessible from the parameter).
+
+The "iteratorElementType" is required if Database control method return type
is java.util.Iterator. It specifies the underlying class of the Iterator that
will be returned by the Database control method.
+
+The "maxRows" element is optional. It sets the maximum number of records to be
returned by the query. The maxRows element limits the size of all types of data
sets, including Arrays, Iterator, ResultSet, etc. The default value of this
element is 1024.
+
+The ConnectionDataSource annotation specifies the data source that the
Database control will use to obtain connection. At the time of writing, this
has not been fully implemented yet. The Database control currently uses the
embedded Derby database driver to obtain connection, and it is expecting the
value provided for the "jndiName" element to be a database URL.
+
+ public @interface ConnectionDataSource
+ {
+ String jndiName(); // no default ... value is required
+ }
+
+The Database control is current included in the Beehive distribution as a
sample control (\samples\controls-db). Building this control with the Ant
script provided will create a dbControl.jar in \samples\controls-db\build\.
You can start creating your own database control extension by simply including
this JAR file in your classpath.
+
+
+ -->
+
+ </p>
+<a name="N10017"></a><a name="Structure+of+the+Database+Control"></a>
<h4>Structure of the Database Control</h4>
<div style="margin-left: 0 ; border: 2px"></div>
<p>The Database Control is a <em>base control</em>: it is designed to be
extented by a <em>control extension</em>. Base controls package the
boilerplate code, the common routines that any code must execute in order to
access a resource. Control extensions contain the interesting, variable
aspects of accessing the resource. If this model were applied to the case of
JMS access, the base control would contain the boilerplate tasks consisting of
obtaining sessions, referencing queues, etc. The control extension configures
the base control for access to a particular JMS resource. The control
extension would anwser the questions: What the JNDI name of the JMS resources?
What message should be sent?
@@ -312,7 +396,7 @@
</ul>
</div>
-<a name="N10047"></a><a name="Distributing+the+Database+Control"></a>
+<a name="N10049"></a><a name="Distributing+the+Database+Control"></a>
<h3>Distributing the Database Control</h3>
<div style="margin-left: 0 ; border: 2px">
<p>[todo]</p>
Modified: incubator/beehive/site/build/site/controls/tutorial_controls.html
==============================================================================
--- incubator/beehive/site/build/site/controls/tutorial_controls.html
(original)
+++ incubator/beehive/site/build/site/controls/tutorial_controls.html Tue Nov
9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/downloads.html
==============================================================================
--- incubator/beehive/site/build/site/downloads.html (original)
+++ incubator/beehive/site/build/site/downloads.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/faq.html
==============================================================================
--- incubator/beehive/site/build/site/faq.html (original)
+++ incubator/beehive/site/build/site/faq.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/index.html
==============================================================================
--- incubator/beehive/site/build/site/index.html (original)
+++ incubator/beehive/site/build/site/index.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/jpetstore.html
==============================================================================
--- incubator/beehive/site/build/site/jpetstore.html (original)
+++ incubator/beehive/site/build/site/jpetstore.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/license.html
==============================================================================
--- incubator/beehive/site/build/site/license.html (original)
+++ incubator/beehive/site/build/site/license.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/mailinglists.html
==============================================================================
--- incubator/beehive/site/build/site/mailinglists.html (original)
+++ incubator/beehive/site/build/site/mailinglists.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/pageflow/guide.html
==============================================================================
--- incubator/beehive/site/build/site/pageflow/guide.html (original)
+++ incubator/beehive/site/build/site/pageflow/guide.html Tue Nov 9
11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
Added: incubator/beehive/site/build/site/pageflow/sample_netui-blank.html
==============================================================================
--- (empty file)
+++ incubator/beehive/site/build/site/pageflow/sample_netui-blank.html Tue Nov
9 11:50:15 2004
@@ -0,0 +1,315 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<title>Page Flow Project Sample</title>
+<link type="text/css" href="../skin/page.css" rel="stylesheet">
+</head>
+<body text="#000000" bgcolor="#FFFFFF">
+<!--================= start Navigation Path ==================-->
+<table summary="navigation path" width="100%" border="0" cellpadding="0"
cellspacing="0">
+<tr>
+<td nowrap="nowrap" valign="middle" bgcolor="#CFDCED" height="20"><img
height="1" width="5" alt="" src="../skin/images/spacer.gif"
class="spacer"><!--===== breadcrumb trail (javascript-generated) ====--><font
size="2" face="Arial, Helvetica, Sans-serif"><script
src="../skin/breadcrumbs.js" language="JavaScript"
type="text/javascript"></script></font></td>
+</tr>
+<tr>
+<td bgcolor="#4C6C8F" height="2"><img height="2" width="2" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+</table>
+<!--================= end Navigation Path ==================-->
+<!--================= start Banner ==================-->
+<table summary="header with logos" width="100%" border="0" cellpadding="0"
cellspacing="0">
+<tr>
+<!--================= start Group Logo ==================-->
+<td bgcolor="#294563"><a href="http://incubator.apache.org/"><img border="0"
class="logoImage" alt="Apache Incubator"
src="../images/_incubator-logo.gif"></a></td>
+<!--================= end Group Logo ==================-->
+<!--================= start Project Logo ==================--><td width="100%"
align="center" bgcolor="#294563"><a
href="http://incubator.apache.org/beehive"><img border="0" class="logoImage"
alt="Apache Beehive" src="../images/_beehive_logo_wide.gif"></a></td>
+<!--================= end Project Logo ==================-->
+<!--================= start Search ==================--><td valign="top"
rowspan="2" bgcolor="#294563">
+<form target="_blank" action="http://www.google.com/search" method="get">
+<table summary="search" border="0" cellspacing="0" cellpadding="0"
bgcolor="#4C6C8F">
+<tr>
+<td colspan="3"><img height="10" width="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td><img height="1" width="1" alt="" src="../skin/images/spacer.gif"
class="spacer"></td><td nowrap="nowrap"><input value="incubator.apache.org"
name="sitesearch" type="hidden"><input size="15" name="q" id="query"
type="text"><img height="1" width="5" alt="" src="../skin/images/spacer.gif"
class="spacer"><input name="Search" value="Search" type="submit">
+<br>
+<font face="Arial, Helvetica, Sans-serif" size="2" color="white">
+ the Apache Beehive site
+
+
+ </font></td><td><img height="1" width="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td><img alt="" border="0" height="10" width="9"
src="../skin/images/search-left.gif"></td><td><img height="1" width="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td><img alt="" border="0"
height="10" width="9" src="../skin/images/search-right.gif"></td>
+</tr>
+</table>
+</form>
+</td>
+<!--================= start Search ==================--><td
bgcolor="#294563"><img height="10" width="10" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td valign="bottom" bgcolor="#294563" colspan="2">
+<!--================= start Tabs ==================-->
+<div class="tab">
+<table summary="tab bar" border="0" cellpadding="0" cellspacing="0">
+<tr>
+<td width="6"><img alt="" height="8" width="6"
src="../skin/images/spacer.gif"></td><td valign="bottom">
+<table summary="selected tab" style="height: 1.8em" border="0" cellpadding="0"
cellspacing="0">
+<tr>
+<td valign="top" width="5" bgcolor="#4C6C8F"><img height="5" width="5" alt=""
src="../skin/images/tabSel-left.gif"></td><td valign="middle"
bgcolor="#4C6C8F"><font color="#ffffff" size="2" face="Arial, Helvetica,
Sans-serif"><b><a class="base-selected"
href="../index.html">Home</a></b></font></td><td valign="top" width="5"
bgcolor="#4C6C8F"><img height="5" width="5" alt=""
src="../skin/images/tabSel-right.gif"></td>
+</tr>
+</table>
+</td>
+</tr>
+</table>
+</div>
+<!--================= end Tabs ==================-->
+</td><td bgcolor="#294563"><img alt="" width="1" height="1"
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td bgcolor="#4C6C8F" colspan="4"><img width="1" height="10" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+</table>
+<!--================= end Banner ==================-->
+<!--================= start Menu, NavBar, Content ==================-->
+<table summary="page content" bgcolor="#ffffff" width="100%" border="0"
cellpadding="0" cellspacing="0">
+<tr>
+<td valign="top">
+<table summary="menu" border="0" cellspacing="0" cellpadding="0">
+<tr>
+<!--================= start left top NavBar ==================-->
+<td rowspan="3" valign="top">
+<table summary="blue line" border="0" cellpadding="0" cellspacing="0">
+<tr>
+<td bgcolor="#294563"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td bgcolor="#CFDCED"><font color="#4C6C8F" size="4" face="Arial, Helvetica,
Sans-serif"> </font></td>
+</tr>
+<tr>
+<td bgcolor="#294563"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+</table>
+</td>
+<!--================= end left top NavBar ==================--><td
bgcolor="#294563"><img width="1" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td valign="bottom"
bgcolor="#4C6C8F"><img width="10" height="10" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td nowrap="nowrap"
valign="top" bgcolor="#4C6C8F">
+<!--================= start Menu items ==================-->
+<div class="menu">
+<ul>
+<li>
+<font color="#CFDCED">Beehive</font>
+<ul>
+
+<li>
+<a href="../index.html">Welcome</a>
+</li>
+
+<li>
+<a href="../license.html">License</a>
+</li>
+
+<li>
+<a href="../downloads.html">Downloads</a>
+</li>
+
+<li>
+<a href="../faq.html">FAQ</a>
+</li>
+
+</ul>
+</li>
+<li>
+<font color="#CFDCED">Documentation</font>
+<ul>
+
+
+<li>
+<font color="#CFDCED">Page Flows</font>
+<ul>
+
+<li>
+<a href="../pageflow/tutorial_pageflow.html">Page Flow Tutorial</a>
+</li>
+
+<li>
+<a href="../pageflow/guide.html">Page Flow Programming</a>
+</li>
+
+</ul>
+</li>
+
+<li>
+<font color="#CFDCED">Controls</font>
+<ul>
+
+<li>
+<a href="../controls/tutorial_controls.html">Control Tutorial</a>
+</li>
+
+<li>
+<a href="../Controls.html">Control Programming</a>
+</li>
+
+</ul>
+</li>
+
+<li>
+<font color="#CFDCED">Web Services</font>
+<ul>
+
+<li>
+<a href="../wsm/tutorial_wsm.html">Web Services Tutorial</a>
+</li>
+
+<li>
+<a href="../webservices.html">Web Services (JSR 181)</a>
+</li>
+
+</ul>
+</li>
+
+<li>
+<font color="#CFDCED">Samples</font>
+<ul>
+
+<li>
+<a href="../jpetstore.html">Petstore</a>
+</li>
+
+<li>
+<a href="../wsm/sample_Dashboard.html">Petstore Dashboard</a>
+</li>
+
+<li>
+<a href="../wsm/sample_AddressBook.html">AddressBook/Employee</a>
+</li>
+
+<li>
+<a href="../controls/sample_controls-db.html">Database Control</a>
+</li>
+
+<li>
+<span class="sel"><font color="#ffcc00">Page Flow Project</font></span>
+</li>
+
+<li>
+<a href="../controls/sample_controls-blank.html">Control Project</a>
+</li>
+
+<li>
+<a href="../wsm/sample_wsm-blank.html">Web Service Project</a>
+</li>
+
+</ul>
+</li>
+
+<li>
+<a href="../reference.html">Reference Docs</a>
+</li>
+
+
+
+</ul>
+</li>
+<li>
+<font color="#CFDCED">Community</font>
+<ul>
+
+<li>
+<a href="../mailinglists.html">Mailing Lists</a>
+</li>
+
+<li>
+<a href="../contributors.html">Contributors</a>
+</li>
+
+</ul>
+</li>
+</ul>
+</div>
+<!--================= end Menu items ==================-->
+</td><td valign="bottom" bgcolor="#4C6C8F"><img width="10" height="10" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td bgcolor="#294563"><img
width="1" height="1" alt="" src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td valign="bottom" align="left" colspan="2" rowspan="2"
bgcolor="#4C6C8F"><img height="10" width="10" border="0" alt=""
src="../skin/images/menu-left.gif"></td><td bgcolor="#4C6C8F"><img height="10"
width="10" alt="" src="../skin/images/spacer.gif" class="spacer"></td><td
valign="bottom" align="right" colspan="2" rowspan="2" bgcolor="#4C6C8F"><img
height="10" width="10" border="0" alt=""
src="../skin/images/menu-right.gif"></td>
+</tr>
+<tr>
+<td height="1" bgcolor="#294563"><img width="1" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+</table>
+</td><td valign="top" width="100%">
+<table summary="content" width="100%" border="0" cellpadding="0"
cellspacing="0">
+<!--================= start middle NavBar ==================-->
+<tr>
+<td colspan="4" bgcolor="#294563"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td align="left" width="10" bgcolor="#CFDCED"><img width="10" height="1"
alt="" src="../skin/images/spacer.gif" class="spacer"></td><td align="left"
width="50%" bgcolor="#CFDCED"><font color="#4C6C8F" size="3" face="Arial,
Helvetica, Sans-serif">
+
+
+ </font><img width="10" height="8" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td align="right"
width="50%" bgcolor="#CFDCED"><font color="#4C6C8F" size="3" face="Arial,
Helvetica, Sans-serif">
+
+
+ </font><img width="10" height="8" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td width="10"
bgcolor="#CFDCED"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<tr>
+<td colspan="4" bgcolor="#294563"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<!--================= end middle NavBar ==================-->
+<!--================= start Content==================-->
+<tr>
+<td align="left" width="10"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td><td colspan="2"
align="left" width="100%">
+<div class="content">
+<table class="title" summary="">
+<tr>
+<td valign="middle">
+<h1>Page Flow Project Sample</h1>
+</td>
+</tr>
+</table>
+<ul class="minitoc">
+<li>
+<a href="#intro">The Page Flow Application Template</a>
+</li>
+</ul>
+
+<a name="N1000C"></a><a name="intro"></a>
+<h3>The Page Flow Application Template</h3>
+<div style="margin-left: 0 ; border: 2px">
+<p>Use the "blank" Page Flow sample (located at <span
class="codefrag">BEEHIVE_HOME/samples/netui-blank</span>) is a template for
building your own Page Flow applications.
+
+</p>
+<p>The sample contains everything needed in a basic Page Flow application,
except for the runtime JAR files. To use the template, (1) copy its contents
into your project folder, and (2) copy the runtime JARs to the WEB-INF/lib
directory. The following Ant command will copy the necessary runtime JARs to
<span class="codefrag"><Project-Folder>/WEB-INF/lib</span>, where <span
class="codefrag"><Project-Folder></span> is the path to your Page Flow
project folder: </p>
+<pre class="code"> ant
+ -f %BEEHIVE_HOME%\ant\buildWebapp.xml
+ -Dwebapp.dir=<Project-Folder>
+ deploy.beehive.webapp.runtime</pre>
+</div>
+
+<div class="attribution"></div>
+</div>
+</td><td width="10"><img width="10" height="1" alt=""
src="../skin/images/spacer.gif" class="spacer"></td>
+</tr>
+<!--================= end Content==================-->
+</table>
+</td>
+</tr>
+</table>
+<!--================= end Menu, NavBar, Content ==================-->
+<!--================= start Footer ==================-->
+<table summary="footer" cellspacing="0" cellpadding="0" width="100%"
border="0">
+<tr>
+<td colspan="2" height="1" bgcolor="#4C6C8F"><img height="1" width="1" alt=""
src="../skin/images/spacer.gif" class="spacer"><a
href="../skin/images/label.gif"></a><a href="../skin/images/page.gif"></a><a
href="../skin/images/chapter.gif"></a><a
href="../skin/images/chapter_open.gif"></a><a
href="../skin/images/current.gif"></a><a href="/favicon.ico"></a></td>
+</tr>
+<tr>
+<td colspan="2" bgcolor="#CFDCED" class="copyright" align="center"><font
size="2" face="Arial, Helvetica, Sans-Serif">Copyright ©
+ 2004 The Apache Software Foundation. All rights
reserved.<script type="text/javascript" language="JavaScript"><!--
+ document.write(" - "+"Last Published: " + document.lastModified);
+ // --></script></font></td>
+</tr>
+<tr>
+<td colspan="2" align="left" bgcolor="#CFDCED" class="logos"></td>
+</tr>
+</table>
+<!--================= end Footer ==================-->
+</body>
+</html>
Modified: incubator/beehive/site/build/site/pageflow/tutorial_pageflow.html
==============================================================================
--- incubator/beehive/site/build/site/pageflow/tutorial_pageflow.html
(original)
+++ incubator/beehive/site/build/site/pageflow/tutorial_pageflow.html Tue Nov
9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/reference.html
==============================================================================
--- incubator/beehive/site/build/site/reference.html (original)
+++ incubator/beehive/site/build/site/reference.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/webservices.html
==============================================================================
--- incubator/beehive/site/build/site/webservices.html (original)
+++ incubator/beehive/site/build/site/webservices.html Tue Nov 9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/wsm/sample_AddressBook.html
==============================================================================
--- incubator/beehive/site/build/site/wsm/sample_AddressBook.html
(original)
+++ incubator/beehive/site/build/site/wsm/sample_AddressBook.html Tue Nov
9 11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/wsm/sample_Dashboard.html
==============================================================================
--- incubator/beehive/site/build/site/wsm/sample_Dashboard.html (original)
+++ incubator/beehive/site/build/site/wsm/sample_Dashboard.html Tue Nov 9
11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
Modified: incubator/beehive/site/build/site/wsm/sample_wsm-blank.html
==============================================================================
--- incubator/beehive/site/build/site/wsm/sample_wsm-blank.html (original)
+++ incubator/beehive/site/build/site/wsm/sample_wsm-blank.html Tue Nov 9
11:50:15 2004
@@ -2,7 +2,7 @@
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>"Blank" Control Sample</title>
+<title>Web Service Project Sample</title>
<link type="text/css" href="../skin/page.css" rel="stylesheet">
</head>
<body text="#000000" bgcolor="#FFFFFF">
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
@@ -258,26 +262,28 @@
<table class="title" summary="">
<tr>
<td valign="middle">
-<h1>"Blank" Control Sample</h1>
+<h1>Web Service Project Sample</h1>
</td>
</tr>
</table>
<ul class="minitoc">
<li>
-<a href="#intro">Distributable Control Projects</a>
+<a href="#intro">The Web Service Application Template</a>
</li>
-<li></li>
</ul>
<a name="N1000C"></a><a name="intro"></a>
-<h3>Distributable Control Projects</h3>
+<h3>The Web Service Application Template</h3>
<div style="margin-left: 0 ; border: 2px">
-<p>"Mentioning the "control project" model for using controls (perhaps as a
2nd controls tutorial?) -- ie, using the controls-blank template to create a
controls JAR that is then importable in multiple webapps (WEB-INF/lib), and
using this to help isolate business logic in controls from presentation logic
in the webapp proper." </p>
+<p>Use the "blank" web service sample (located at <span
class="codefrag">BEEHIVE_HOME/samples/wsm-blank</span>) is a template for
building your own web service applications.
+
+</p>
+<p>The sample contains everything needed in a basic web service application,
except for the runtime JAR files. To use the template, (1) copy its contents
into your project folder, and (2) copy the runtime JARs to the WEB-INF/lib
directory. The following Ant command will copy the necessary runtime JARs to
<span class="codefrag"><Project-Folder>/WEB-INF/lib</span>, where <span
class="codefrag"><Project-Folder></span> is the path to your web service
project folder: </p>
+<pre class="code"> ant
+ -f %BEEHIVE_HOME%\ant\buildWebapp.xml
+ -Dwebapp.dir=<Project-Folder>
+ deploy.wsm.webapp.runtime</pre>
</div>
-
-<a name="N10016"></a>
-<h3></h3>
-<div style="margin-left: 0 ; border: 2px"></div>
<div class="attribution"></div>
</div>
Modified: incubator/beehive/site/build/site/wsm/tutorial_wsm.html
==============================================================================
--- incubator/beehive/site/build/site/wsm/tutorial_wsm.html (original)
+++ incubator/beehive/site/build/site/wsm/tutorial_wsm.html Tue Nov 9
11:50:15 2004
@@ -188,6 +188,10 @@
</li>
<li>
+<a href="../pageflow/sample_netui-blank.html">Page Flow Project</a>
+</li>
+
+<li>
<a href="../controls/sample_controls-blank.html">Control Project</a>
</li>
@@ -264,12 +268,7 @@
</table>
<ul class="minitoc">
<li>
-<a href="#intro">Introduction to the Web Service Tutorial</a>
-<ul class="minitoc">
-<li>
-<a href="#Tutorial+Goals">Tutorial Goals</a>
-</li>
-</ul>
+<a href="#intro">Introduction</a>
</li>
<li>
<a href="#step1">Step 1: Begin the Web Service Tutorial</a>
@@ -341,7 +340,7 @@
<a href="#Step+4%3A+Add+a+Non-Web+Invokable+Method">Step 4: Add a Non-Web
Invokable Method</a>
<ul class="minitoc">
<li>
-<a href="#Compile+and+Redeploy+the+Web+Service-N101F6">Compile and Redeploy
the Web Service</a>
+<a href="#Compile+and+Redeploy+the+Web+Service-N101FC">Compile and Redeploy
the Web Service</a>
</li>
<li>
<a href="#To+Test+the+Non-Web+Invokable+Method">To Test the Non-Web Invokable
Method</a>
@@ -354,11 +353,12 @@
</ul>
<a name="N1000D"></a><a name="intro"></a>
-<h3>Introduction to the Web Service Tutorial</h3>
-<div style="margin-left: 0 ; border: 2px">
-<a name="N10013"></a><a name="Tutorial+Goals"></a>
-<h4>Tutorial Goals</h4>
+<h3>Introduction</h3>
<div style="margin-left: 0 ; border: 2px">
+<p>This tutorial introduces you to the basic development cycle for Beehive web
services. The tutorial assumes that you are working on a Windows machine.
But, with a little common sense, it is easy to execute the tutorial on a Unix
machine. For example, when you are asked to run the file <span
class="codefrag">beehiveUser.cmd</span>, run the file <span
class="codefrag">beehiveUser.sh</span> instead.</p>
+<p>
+<strong>Tutorial Goals</strong>
+</p>
<p>In this tutorial, you will learn:</p>
<ul>
@@ -370,26 +370,25 @@
</ul>
</div>
-</div>
-<a name="N1002A"></a><a name="step1"></a>
+<a name="N10030"></a><a name="step1"></a>
<h3>Step 1: Begin the Web Service Tutorial</h3>
<div style="margin-left: 0 ; border: 2px">
-<a name="N10030"></a><a name="To+Download+and+Install+J2SE5"></a>
+<a name="N10036"></a><a name="To+Download+and+Install+J2SE5"></a>
<h4>To Download and Install J2SE5</h4>
<div style="margin-left: 0 ; border: 2px">
<p>If you do not have J2SE5 installed, visit <a target="_blank"
href="http://java.sun.com/j2se/1.5.0/download.jsp">http://java.sun.com/j2se/1.5.0/download.jsp</a>.
</p>
<p>Download and install the latest version of J2SE5.</p>
</div>
-<a name="N10041"></a><a name="To+Install+ANT+1.6.2"></a>
+<a name="N10047"></a><a name="To+Install+ANT+1.6.2"></a>
<h4>To Install ANT 1.6.2</h4>
<div style="margin-left: 0 ; border: 2px">
<p>If you do not have Ant 1.6.2 installed, visit <a target="_blank"
href="http://svn.apache.org/repos/asf/incubator/beehive/trunk/external/ant/apache-ant-1.6.2-bin.zip">http://svn.apache.org/repos/asf/incubator/beehive/trunk/external/ant/apache-ant-1.6.2-bin.zip</a>.
</p>
<p>Download the ZIP file and unzip it on your machine.</p>
</div>
-<a name="N10052"></a><a name="To+Download+and+Install+Tomcat+5"></a>
+<a name="N10058"></a><a name="To+Download+and+Install+Tomcat+5"></a>
<h4>To Download and Install Tomcat 5</h4>
<div style="margin-left: 0 ; border: 2px">
<p>If you do not have Tomcat 5 installed, visit <a target="_blank"
href="http://svn.apache.org/repos/asf/incubator/beehive/trunk/external/tomcat/jakarta-tomcat-5.0.25.zip">http://svn.apache.org/repos/asf/incubator/beehive/trunk/external/tomcat/jakarta-tomcat-5.0.25.zip</a>
@@ -397,13 +396,13 @@
</p>
<p>Download the ZIP file and unzip it on your machine.</p>
</div>
-<a name="N10063"></a><a
name="To+Download+and+Install+a+Beehive+Binary+Distribution"></a>
+<a name="N10069"></a><a
name="To+Download+and+Install+a+Beehive+Binary+Distribution"></a>
<h4>To Download and Install a Beehive Binary Distribution</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Visit [todo: distribution download link] and download the latest binary
distribution of Beehive.</p>
<p>Unzip the distribution file on your machine</p>
</div>
-<a name="N10070"></a><a name="To+Set+up+the+Development+Environment"></a>
+<a name="N10076"></a><a name="To+Set+up+the+Development+Environment"></a>
<h4>To Set up the Development Environment</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Open the directory where you installed the Beehive distribution. Open the
file <span class="codefrag">beehiveUser.cmd</span> in a text editor. Edit
<span class="codefrag">beehiveUser.cmd</span> to fit your local environment.
The following environmental variables must be set to the appropriate paths on
your machine: <span class="codefrag">BEEHIVE_HOME</span>, <span
class="codefrag">JAVA_HOME</span>, <span class="codefrag">ANT_HOME</span>, and
<span class="codefrag">CATALINA_HOME</span>. The following example shows how
to edit <span class="codefrag">beehiveUser.cmd</span> for a typical
environment.</p>
@@ -426,7 +425,7 @@
</p>
<p>Leave the command shell open to use throughout the tutorial</p>
</div>
-<a name="N100AC"></a><a name="Add+a+Manager+Role+to+Tomcat"></a>
+<a name="N100B2"></a><a name="Add+a+Manager+Role+to+Tomcat"></a>
<h4>Add a Manager Role to Tomcat</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Adding the manager role to Tomcat server allows you to run deploy related
targets in the Ant file <span class="codefrag">runTomcat.xml</span>. This file
is provided as a convenience for managing the Tomcat server.</p>
@@ -442,7 +441,7 @@
<user username="manager" password="manager" roles="manager"/>
</tomcat-users></pre>
</div>
-<a name="N100C4"></a><a name="To+Start+the+Tomcat+Server"></a>
+<a name="N100CA"></a><a name="To+Start+the+Tomcat+Server"></a>
<h4>To Start the Tomcat Server</h4>
<div style="margin-left: 0 ; border: 2px">
<p>At the command prompt, enter:</p>
@@ -450,15 +449,15 @@
</div>
</div>
-<a name="N100D4"></a><a name="step_2"></a>
+<a name="N100DA"></a><a name="step_2"></a>
<h3>Step 2: Install the Web Service Template</h3>
<div style="margin-left: 0 ; border: 2px">
-<a name="N100DA"></a><a name="Introduction"></a>
+<a name="N100E0"></a><a name="Introduction"></a>
<h4>Introduction</h4>
<div style="margin-left: 0 ; border: 2px">
<p>[todo]</p>
</div>
-<a name="N100E4"></a><a name="Make+a+Project+Folder"></a>
+<a name="N100EA"></a><a name="Make+a+Project+Folder"></a>
<h4>Make a Project Folder</h4>
<div style="margin-left: 0 ; border: 2px">
<p>On your C: drive, create a directory called <span
class="codefrag">beehive_projects</span>.</p>
@@ -468,7 +467,7 @@
beehive_projects
ws_tutorial</pre>
</div>
-<a name="N100FF"></a><a
name="To+Copy+the+Web+Services+Application+Template"></a>
+<a name="N10105"></a><a
name="To+Copy+the+Web+Services+Application+Template"></a>
<h4>To Copy the Web Services Application Template</h4>
<div style="margin-left: 0 ; border: 2px">
<p>In this step you will copy the Web Services project template into your
project folder. The project template contains a simple web service and a test
JSP page.</p>
@@ -485,7 +484,7 @@
happyaxis.jsp
index.html</pre>
</div>
-<a name="N1012D"></a><a
name="Copy+the+Runtime+JARs+into+the+Project+Folder"></a>
+<a name="N10133"></a><a
name="Copy+the+Runtime+JARs+into+the+Project+Folder"></a>
<h4>Copy the Runtime JARs into the Project Folder</h4>
<div style="margin-left: 0 ; border: 2px">
<p>To copy the runtime JARs into your project, run the following Ant
command:</p>
@@ -495,7 +494,7 @@
deploy.wsm.webapp.runtime</pre>
<p>This will copy the JAR files from <span
class="codefrag">BEEHIVE_HOME/lib/wsm</span> into <span
class="codefrag">C:/beehive_projects/ws_tutorial/WEB-INF/lib</span>.</p>
</div>
-<a name="N10145"></a><a name="Examine+the+Blank.jws+Web+Service"></a>
+<a name="N1014B"></a><a name="Examine+the+Blank.jws+Web+Service"></a>
<h4>Examine the Blank.jws Web Service</h4>
<div style="margin-left: 0 ; border: 2px">
<p>You are now ready to compile and run your web service.</p>
@@ -522,14 +521,14 @@
<p>
<span class="codefrag">@WebService</span> and <span
class="codefrag">@WebMethod</span> are "metadata annotations", a.k.a.
"annotations". Annotations allow you to set properties on Java classes and
methods. They can be used to generate compile-time artifacts such as
configuration files or Java classes (this is how many Beehive Control
annotations work) or to determine some runtime behavior (this is how Beehive
Web Service annotations work). <span class="codefrag">@WebService</span>
annotates (or "decorates") the class Blank: this tells the runtime that Blank
is a web service that listens for SOAP messages and responds in kind. <span
class="codefrag">@WebMethod</span> annotates the method sayHelloWorld(): this
tells the runtime that the method can be invoked over the web.</p>
</div>
-<a name="N10170"></a><a name="Compile+and+Deploy+the+Web+Service"></a>
+<a name="N10176"></a><a name="Compile+and+Deploy+the+Web+Service"></a>
<h4>Compile and Deploy the Web Service</h4>
<div style="margin-left: 0 ; border: 2px">
<p>In this step you will compile the web service and deploy it to Tomcat, all
in one step.</p>
<p>Run the following Ant command:</p>
<pre class="code">ant -f %BEEHIVE_HOME%\ant\buildWebapp.xml
-Dwebapp.dir=C:\beehive_projects\ws_tutorial -Dcontext.path=ws_tutorial
build.webapp deploy</pre>
</div>
-<a name="N10182"></a><a
name="To+Run+the+Web+Service+Provided+in+the+Template"></a>
+<a name="N10188"></a><a
name="To+Run+the+Web+Service+Provided+in+the+Template"></a>
<h4>To Run the Web Service Provided in the Template</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Visit the index.jsp page: <a target="_blank"
href="http://localhost:8080/ws_tutorial/index.jsp">http://localhost:8080/ws_tutorial/index.jsp</a>.</p>
@@ -539,10 +538,10 @@
</div>
</div>
-<a name="N1019A"></a><a name="step_3"></a>
+<a name="N101A0"></a><a name="step_3"></a>
<h3>Step 3: Add a Parameterized Method to the Web Service</h3>
<div style="margin-left: 0 ; border: 2px">
-<a name="N101A0"></a><a name="Edit+the+JWS+File"></a>
+<a name="N101A6"></a><a name="Edit+the+JWS+File"></a>
<h4>Edit the JWS File</h4>
<div style="margin-left: 0 ; border: 2px">
<p></p>
@@ -575,14 +574,14 @@
}</pre>
<p>The <span class="codefrag">@WebParam</span> you just added lets you pass a
String parameter to the method over the web. The <span
class="codefrag">name="greetee"</span> attribute is optional. If you do not
explicitly specify a <span class="codefrag">name</span> attribute, the
parameter will take the default name <span class="codefrag">str0</span>
[<--- todo: verify].</p>
</div>
-<a name="N101C3"></a><a name="Compile+and+Redeploy+the+Web+Service"></a>
+<a name="N101C9"></a><a name="Compile+and+Redeploy+the+Web+Service"></a>
<h4>Compile and Redeploy the Web Service</h4>
<div style="margin-left: 0 ; border: 2px">
<p>At the command prompt, enter the following Ant command:</p>
<pre class="code">ant -f %BEEHIVE_HOME%\ant\buildWebapp.xml
-Dwebapp.dir=C:\beehive_projects\ws_tutorial -Dcontext.path=ws_tutorial
build.webapp redeploy</pre>
<p>This Ant command compiles the app, undeploys it, and then deploys it.
Calling <span class="codefrag">ant ... redeploy</span> is equivalent to calling
<span class="codefrag">ant ... undeploy deploy</span>.</p>
</div>
-<a name="N101DB"></a><a name="Test+the+Parameterized+Method"></a>
+<a name="N101E1"></a><a name="Test+the+Parameterized+Method"></a>
<h4>Test the Parameterized Method</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Enter the following URL in the address bar of your browser. </p>
@@ -599,7 +598,7 @@
</div>
</div>
-<a name="N101F1"></a><a name="Step+4%3A+Add+a+Non-Web+Invokable+Method"></a>
+<a name="N101F7"></a><a name="Step+4%3A+Add+a+Non-Web+Invokable+Method"></a>
<h3>Step 4: Add a Non-Web Invokable Method</h3>
<div style="margin-left: 0 ; border: 2px">
<p>Edit the file <span
class="codefrag">C:/beehive_projects/ws_tutorial/WEB-INF/src/template/Blank.jws</span>
so it appears as follows.</p>
@@ -636,14 +635,14 @@
}
</pre>
<p>Note that the method added, sayNothingOverTheWeb(), does not have the
annotation @WebMethod, indicating that it cannot be invoked by SOAP messages
over the web.</p>
-<a name="N10205"></a><a name="Compile+and+Redeploy+the+Web+Service-N101F6"></a>
+<a name="N1020B"></a><a name="Compile+and+Redeploy+the+Web+Service-N101FC"></a>
<h4>Compile and Redeploy the Web Service</h4>
<div style="margin-left: 0 ; border: 2px">
<p>At the command prompt, enter the following Ant command:</p>
<pre class="code">ant -f %BEEHIVE_HOME%\ant\buildWebapp.xml
-Dwebapp.dir=C:\beehive_projects\ws_tutorial -Dcontext.path=ws_tutorial
build.webapp redeploy</pre>
<p>This Ant command compiles the app, undeploys it, and then deploys it.
Calling <span class="codefrag">ant ... redeploy</span> is equivalent to calling
<span class="codefrag">ant ... undeploy deploy</span>.</p>
</div>
-<a name="N1021D"></a><a name="To+Test+the+Non-Web+Invokable+Method"></a>
+<a name="N10223"></a><a name="To+Test+the+Non-Web+Invokable+Method"></a>
<h4>To Test the Non-Web Invokable Method</h4>
<div style="margin-left: 0 ; border: 2px">
<p>Enter the following URL in the address bar of your browser. </p>
@@ -661,7 +660,7 @@
</soapenv:Body>
</soapenv:Envelope> </pre>
</div>
-<a name="N10232"></a><a name="Step+5%3A+Change+the+SOAP+Style"></a>
+<a name="N10238"></a><a name="Step+5%3A+Change+the+SOAP+Style"></a>
<h4>Step 5: Change the SOAP Style</h4>
<div style="margin-left: 0 ; border: 2px">
<p>The default SOAP style for JSR-181 web services is DOC-literal. In this
step you will change the style to RPC-encoded.</p>
@@ -699,13 +698,13 @@
return "Not for for Web consumption!";
}
}</pre>
-<a name="N10246"></a><a name="Compile+and+Redeploy+the+Web+Service-N10234"></a>
+<a name="N1024C"></a><a name="Compile+and+Redeploy+the+Web+Service-N1023A"></a>
<h5>Compile and Redeploy the Web Service</h5>
<div style="margin-left: 0 ; border: 2px">
<p>At the command prompt, enter the following Ant command:</p>
<pre class="code">ant -f %BEEHIVE_HOME%\ant\buildWebapp.xml
-Dwebapp.dir=C:\beehive_projects\ws_tutorial -Dcontext.path=ws_tutorial
build.webapp redeploy</pre>
</div>
-<a name="N10255"></a><a name="To+Test+the+Non-Web+Invokable+Method-N10242"></a>
+<a name="N1025B"></a><a name="To+Test+the+Non-Web+Invokable+Method-N10248"></a>
<h5>To Test the Non-Web Invokable Method</h5>
<div style="margin-left: 0 ; border: 2px">
<p>Enter the following URL in the address bar of your browser. </p>
Modified:
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-blank.xml
==============================================================================
---
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-blank.xml
(original)
+++
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-blank.xml
Tue Nov 9 11:50:15 2004
@@ -2,16 +2,37 @@
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.2//EN"
"http://forrest.apache.org/dtd/document-v13.dtd">
<document>
<header>
- <title>"Blank" Control Sample</title>
+ <title>Control Project Sample</title>
</header>
<body>
- <section id="intro">
- <title>Distributable Control Projects</title>
-<p>"Mentioning the "control project" model for using controls (perhaps as a
2nd controls tutorial?) -- ie, using the controls-blank template to create a
controls JAR that is then importable in multiple webapps (WEB-INF/lib), and
using this to help isolate business logic in controls from presentation logic
in the webapp proper." </p>
- </section>
- <section>
- <title></title>
+ <section id="intro">
+ <title>The Control Application Template</title>
+<p>Use the "blank" Control sample (located at
<code>BEEHIVE_HOME/samples/controls-blank</code>) is a template for building
your own Control projects.
+
+</p>
+
+<p>The template contains a basic 'Hello World' control to get you started.
Control projects can be archived in a JAR file and then imported into multiple
applications. Simple import the JAR archive into the application's WEB-INF/lib
directory. </p>
+<!--<source>
+netui-blank
+ resources
+ beehive
+ version
+ images
+ error-handling.jpg - header image for the error.jsp page
+ javascript
+ netui-tree.js - JavaScript file to support the <netui:tree> tag
+ WEB-INF
+ src
+ global
+ Global.app - a global Page Flow useful for common operations, error
handling, etc.
+ log4j.xml - the log4j configuration file
+ netui-config.xml -
+ netui-validator-rules.xml
+ web.xml
+</source>-->
</section>
+
+
</body>
<footer>
<legal>Java, J2EE, and JCP are trademarks or registered trademarks of
Sun Microsystems, Inc. in the United States and other countries.<br/>
Modified:
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-db.xml
==============================================================================
---
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-db.xml
(original)
+++
incubator/beehive/site/src/documentation/content/xdocs/controls/sample_controls-db.xml
Tue Nov 9 11:50:15 2004
@@ -7,7 +7,87 @@
<body>
<section>
<title>Control Programming: Simplifying Access to Resources</title>
- <p>Control Programming...simplifying access to a resource, in this
case a database.</p>
+ <p>Control Programming...simplifying access to a resource, in this
case a database.
+
+ <!-- From Hoi Lam's email:
+ A Database control makes it easy to access a relational database from
your Java code using SQL commands. The Database control handles the work of
connecting to the database, so you don’t have to understand JDBC to work with
a database.
+
+All Database controls are subclassed from the DatabaseControl interface. The
interface defines methods that Database control instances can call from an
application.
+
+The methods that you add to a Database control execute SQL commands against
the database. You can send any SQL command to the database via the Database
control, so that you can retrieve data, perform operations like inserts and
updates.
+
+A method on a Database control always has an associated SQL statement, which
executes against the database when the method is called. The method’s @SQL
annotation describes the method’s SQL statement. The method’s SQL
statement may include substitution parameters. These parameters are replaced at
runtime with the values that were passed to the method. The names of the
substitution parameters in the SQL statement must match those in the method
signature, so that the Database control knows which parameter to replace with
which value.
+
+The following example Database control method illustrates using parameter
substitution in Database control methods:
+
+ @SQL(statement="INSERT INTO EMPLOYEE " +
+ "(id, fName, lName, title) " +
+ "VALUES ({emp.id}, {emp.fName}, {emp.lName}, {emp.title})")
+ public void insertEmployee(Employee emp) throws SQLException;
+
+In the example above, the SQL statement includes the substitution {emp.id},
{emp.fName}, ... These map to the various class variables of the "emp"
parameter in the insertEmployee method. When the method is invoked, the values
of any referenced parameters are substituted in the SQL statement before it is
executed. Note that parameter substitution is case sensitive, so parameters
mentioned in substitutions must exactly match the spelling and case of the
parameters to the method.
+
+The return type of the database operation is determined by the return type of
the Java method. The Database control attempts to format the results in
whatever type you have specified for the method to return. A method of a
Database control can return a single value, a single row, or multiple rows.
+
+When your method returns a single value, its return type must be compatible
with the value returned from the query. The following example looks up an
employee's title.
+
+ @SQL(statement="SELECT title FROM EMPLOYEE WHERE id={id}")
+ public String getEmployeeTitle(int id) throws SQLException;
+
+In this example, the title field is of type VARCHAR, so the return value is
declared as String.
+
+When your method returns a single row with multiple fields, its return type
can be a user-defined object or a java.util.HashMap object. When the return
type is a user-defined object, it must contain members with names that match
the names of the columns that will be returned by the query. Because database
column names are case-insensitive, the matching names are case-insensitive. The
class may also contain other members, members not matching any column names
will not be set. The following example declares an Employee class with members
corresponding to fields in the Employee table. The findEmployee method returns
an object of type Employee:
+
+ @SQL(statement="SELECT * FROM EMPLOYEE WHERE id={id}")
+ public Employee findEmployee(int id) throws SQLException;
+
+ public class Employee
+ {
+ public int id;
+ public String fName;
+ public String lName;
+ public String title;
+ }
+
+When your method returns multiple rows from the database, its return type can
be an array, a java.util.Iterator, or a java.sql.ResultSet.
+When you want to return an Iterator object, you must specify the
iteratorElementType element to the @SQL annotation to indicate the underlying
type that the Iterator will contain. The following example returns a iterator
of all employees sorted by their last names.
+
+ @SQL(statement="SELECT * FROM EMPLOYEE ORDER BY lName",
iteratorElementType=Employee.class, maxRows=500)
+ public Iterator getEmployeesSortedByLastName() throws SQLException;
+
+You can limit the number of rows returned by setting the maxRows element of
the @SQL annotation. This element can protect you from very large resultsets
that may be returned by very general queries. The default value of maxRow is
1024.
+
+The Database Control defines two annotations: SQL and ConnectionDataSource.
+
+The SQL Annotation specifies the SQL statement and associated attributes that
correspond to a method in a Database control.
+
+ public @interface SQL
+ {
+ String statement() default "";
+ int maxRows() default MAXROWS_ALL;
+ @AnnotationMemberTypes.Optional
+ Class iteratorElementType() default UndefinedIteratorType.class;
+ }
+
+The "statement" element is required. It specifies the SQL (Structured Query
Language) statement that will be executed when the associated Database control
method is invoked. The statement may contain substitutions of the form
{varName}, where paramName is a parameter of the Database control method (or a
member accessible from the parameter).
+
+The "iteratorElementType" is required if Database control method return type
is java.util.Iterator. It specifies the underlying class of the Iterator that
will be returned by the Database control method.
+
+The "maxRows" element is optional. It sets the maximum number of records to be
returned by the query. The maxRows element limits the size of all types of data
sets, including Arrays, Iterator, ResultSet, etc. The default value of this
element is 1024.
+
+The ConnectionDataSource annotation specifies the data source that the
Database control will use to obtain connection. At the time of writing, this
has not been fully implemented yet. The Database control currently uses the
embedded Derby database driver to obtain connection, and it is expecting the
value provided for the "jndiName" element to be a database URL.
+
+ public @interface ConnectionDataSource
+ {
+ String jndiName(); // no default ... value is required
+ }
+
+The Database control is current included in the Beehive distribution as a
sample control (\samples\controls-db). Building this control with the Ant
script provided will create a dbControl.jar in \samples\controls-db\build\.
You can start creating your own database control extension by simply including
this JAR file in your classpath.
+
+
+ -->
+
+ </p>
<section>
<title>Structure of the Database Control</title>
</section>
Added:
incubator/beehive/site/src/documentation/content/xdocs/pageflow/sample_netui-blank.xml
==============================================================================
--- (empty file)
+++
incubator/beehive/site/src/documentation/content/xdocs/pageflow/sample_netui-blank.xml
Tue Nov 9 11:50:15 2004
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.2//EN"
"http://forrest.apache.org/dtd/document-v13.dtd">
+<document>
+ <header>
+ <title>Page Flow Project Sample</title>
+ </header>
+ <body>
+ <section id="intro">
+ <title>The Page Flow Application Template</title>
+<p>Use the "blank" Page Flow sample (located at
<code>BEEHIVE_HOME/samples/netui-blank</code>) is a template for building your
own Page Flow applications.
+
+</p>
+
+<p>The sample contains everything needed in a basic Page Flow application,
except for the runtime JAR files. To use the template, (1) copy its contents
into your project folder, and (2) copy the runtime JARs to the WEB-INF/lib
directory. The following Ant command will copy the necessary runtime JARs to
<code><Project-Folder>/WEB-INF/lib</code>, where
<code><Project-Folder></code> is the path to your Page Flow project folder:
</p>
+<source> ant
+ -f %BEEHIVE_HOME%\ant\buildWebapp.xml
+ -Dwebapp.dir=<Project-Folder>
+ deploy.beehive.webapp.runtime</source>
+<!--<source>
+netui-blank
+ resources
+ beehive
+ version
+ images
+ error-handling.jpg - header image for the error.jsp page
+ javascript
+ netui-tree.js - JavaScript file to support the <netui:tree> tag
+ WEB-INF
+ src
+ global
+ Global.app - a global Page Flow useful for common operations, error
handling, etc.
+ log4j.xml - the log4j configuration file
+ netui-config.xml -
+ netui-validator-rules.xml
+ web.xml
+</source>-->
+ </section>
+ </body>
+ <footer>
+ <legal>Java, J2EE, and JCP are trademarks or registered trademarks of
Sun Microsystems, Inc. in the United States and other countries.<br/>
+ © 2004, Apache Software Foundation
+ </legal>
+ </footer>
+</document>
Modified: incubator/beehive/site/src/documentation/content/xdocs/site.xml
==============================================================================
--- incubator/beehive/site/src/documentation/content/xdocs/site.xml
(original)
+++ incubator/beehive/site/src/documentation/content/xdocs/site.xml Tue Nov
9 11:50:15 2004
@@ -27,6 +27,7 @@
<dash label="Petstore Dashboard" href="wsm/sample_Dashboard.html"/>
<address label="AddressBook/Employee"
href="wsm/sample_AddressBook.html"/>
<db label="Database Control"
href="controls/sample_controls-db.html"/>
+ <control-blank label="Page Flow Project"
href="pageflow/sample_netui-blank.html"/>
<control-blank label="Control Project"
href="controls/sample_controls-blank.html"/>
<wsm-blank label="Web Service Project"
href="wsm/sample_wsm-blank.html"/>
</samples>
Modified:
incubator/beehive/site/src/documentation/content/xdocs/wsm/sample_wsm-blank.xml
==============================================================================
---
incubator/beehive/site/src/documentation/content/xdocs/wsm/sample_wsm-blank.xml
(original)
+++
incubator/beehive/site/src/documentation/content/xdocs/wsm/sample_wsm-blank.xml
Tue Nov 9 11:50:15 2004
@@ -2,15 +2,38 @@
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.2//EN"
"http://forrest.apache.org/dtd/document-v13.dtd">
<document>
<header>
- <title>"Blank" Control Sample</title>
+ <title>Web Service Project Sample</title>
</header>
<body>
<section id="intro">
- <title>Distributable Control Projects</title>
-<p>"Mentioning the "control project" model for using controls (perhaps as a
2nd controls tutorial?) -- ie, using the controls-blank template to create a
controls JAR that is then importable in multiple webapps (WEB-INF/lib), and
using this to help isolate business logic in controls from presentation logic
in the webapp proper." </p>
- </section>
- <section>
- <title></title>
+ <title>The Web Service Application Template</title>
+<p>Use the "blank" web service sample (located at
<code>BEEHIVE_HOME/samples/wsm-blank</code>) is a template for building your
own web service applications.
+
+</p>
+
+<p>The sample contains everything needed in a basic web service application,
except for the runtime JAR files. To use the template, (1) copy its contents
into your project folder, and (2) copy the runtime JARs to the WEB-INF/lib
directory. The following Ant command will copy the necessary runtime JARs to
<code><Project-Folder>/WEB-INF/lib</code>, where
<code><Project-Folder></code> is the path to your web service project
folder: </p>
+<source> ant
+ -f %BEEHIVE_HOME%\ant\buildWebapp.xml
+ -Dwebapp.dir=<Project-Folder>
+ deploy.wsm.webapp.runtime</source>
+<!--<source>
+netui-blank
+ resources
+ beehive
+ version
+ images
+ error-handling.jpg - header image for the error.jsp page
+ javascript
+ netui-tree.js - JavaScript file to support the <netui:tree> tag
+ WEB-INF
+ src
+ global
+ Global.app - a global Page Flow useful for common operations, error
handling, etc.
+ log4j.xml - the log4j configuration file
+ netui-config.xml -
+ netui-validator-rules.xml
+ web.xml
+</source>-->
</section>
</body>
<footer>
Modified:
incubator/beehive/site/src/documentation/content/xdocs/wsm/tutorial_wsm.xml
==============================================================================
--- incubator/beehive/site/src/documentation/content/xdocs/wsm/tutorial_wsm.xml
(original)
+++ incubator/beehive/site/src/documentation/content/xdocs/wsm/tutorial_wsm.xml
Tue Nov 9 11:50:15 2004
@@ -7,16 +7,15 @@
</header>
<body>
<section id="intro">
- <title>Introduction to the Web Service Tutorial</title>
- <section>
- <title>Tutorial Goals</title>
+ <title>Introduction</title>
+ <p>This tutorial introduces you to the basic development cycle for
Beehive web services. The tutorial assumes that you are working on a Windows
machine. But, with a little common sense, it is easy to execute the tutorial
on a Unix machine. For example, when you are asked to run the file
<code>beehiveUser.cmd</code>, run the file <code>beehiveUser.sh</code>
instead.</p>
+ <p><strong>Tutorial Goals</strong></p>
<p>In this tutorial, you will learn:</p>
<ul>
<li>How to create a basic Beehive web service
application.</li>
<li>How to use (JSR 175 and 181) metadata annotations.</li>
<li>How to deploy and test a web service to Tomcat</li>
</ul>
- </section>
</section>
<section id="step1">
<title>Step 1: Begin the Web Service Tutorial</title>