You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-dev@jakarta.apache.org by sh...@apache.org on 2001/07/08 18:13:34 UTC

cvs commit: jakarta-taglibs/benchmark/xml intro.xml

shawn       01/07/08 09:13:34

  Modified:    benchmark build.xml
               benchmark/examples/web benchmark1.jsp benchmark2.jsp
  Added:       benchmark/xml intro.xml
  Removed:     benchmark build.bat build.sh
  Log:
  New build process and documentation.
  
  Revision  Changes    Path
  1.6       +10 -202   jakarta-taglibs/benchmark/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/benchmark/build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- build.xml	2001/07/02 02:03:18	1.5
  +++ build.xml	2001/07/08 16:13:29	1.6
  @@ -1,207 +1,15 @@
  -<!-- ANT Build Script for the "benchmark" Custom Tag Library -->
  -<project name="jspspec" default="main" basedir=".">
  +<?xml version="1.0"?>
   
  -    <!-- ******************** Adjustable Properties *********************** -->
  +<!DOCTYPE project [
  +    <!ENTITY common SYSTEM "file:../common.xml">
  +]>
   
  -    <!--
  +<project name="benchmark" default="main">
   
  -        The following property values should be examined and customized
  -	for each custom tag library subproject.
  -
  -	ant.home                    Home directory for the ANT build tool
  -	                            This is normally defaulted from the
  -				    ANT_HOME environment variable in the
  -				    build script.
  -
  -	servlet.jar                 Pathname of the servlet API classes
  -	                            you are using to compile, such as the
  -				    one that comes with Tomcat.  This is
  -				    normally defaulted from the SERVLET_JAR
  -				    environment variable in the build script.
  -
  -        taglib.name		    Base name of this tag library subproject.
  -
  -    -->
  -
  -    <property name="taglib.name"    value="benchmark"/>
  -    <property name="servlet.jar"    value="../../jakarta-servletapi/lib/servlet.jar"/>
  -
  -    <!-- ****************** Project Standard Properties ******************* -->
  -
  -    <!--
  -
  -        The following property values reflect the standard directory
  -	organization for the jakarta-taglibs project, and should not
  -	be changed or overridden.
  -
  -	build.dir                   Base directory for build targets
  -	dist.dir                    Base directory for distribution targets
  -        taglibs.xsl                 Taglibs stylesheet
  -
  -    -->
  -
  -    <property name="build.dir"      value="../build"/>
  -    <property name="dist.dir"       value="../dist"/>
  -    <property name="taglibs.xsl"    value="../src/doc/stylesheets/taglibs.xsl"/>
  -
  -    <!-- *********************** Default Properties ********************** -->
  -
  -    <!--
  -
  -        The following property values reflect the recommended directory
  -	structure for each custom tag library subproject.  You should only
  -	need to adjust or override them if you use a different organization.
  -
  -	conf.src                    Library configuration source directory
  -        doc.src                     Documentation app source directory
  -        examples.src                Examples app source directory
  -        library.src                 Library Java source directory
  -
  -    -->
  -
  -    <property name="conf.src"       value="conf"/>
  -    <property name="doc.src"        value="doc"/>
  -    <property name="examples.src"   value="examples"/>
  -    <property name="library.src"    value="src"/>
  -
  -
  -    <!-- ********************* Derived Properties ************************* -->
  -
  -    <!--
  -
  -        These property values are derived from the previously defined values,
  -	and should not normally be overridden from the command line.
  -
  -        build.doc                   Target directory for documentation app
  -        build.examples		    Target directory for examples app
  -        build.library               Target directory for tag library
  -	dist.doc                    Destination WAR for documentation app
  -	dist.examples		    Destination WAR for examples app
  -	dist.library                Destination JAR for tag library
  -	dist.tld                    Destination TLD file for tag library
  -
  -    -->
  -
  -    <property name="build.doc"      value="${build.dir}/${taglib.name}/${taglib.name}-doc"/>
  -    <property name="build.examples" value="${build.dir}/${taglib.name}/${taglib.name}-examples"/>
  -    <property name="build.library"  value="${build.dir}/${taglib.name}/${taglib.name}"/>
  -    <property name="dist.doc"       value="${dist.dir}/${taglib.name}/${taglib.name}-doc.war"/>
  -    <property name="dist.examples"  value="${dist.dir}/${taglib.name}/${taglib.name}-examples.war"/>
  -    <property name="dist.library"   value="${dist.dir}/${taglib.name}/${taglib.name}.jar"/>
  -    <property name="dist.tld"       value="${dist.dir}/${taglib.name}/${taglib.name}.tld"/>
  -    <property name="taglibs.doc"    value="${dist.dir}/doc/doc/${taglib.name}-doc"/>
  -
  -
  -  <!-- ********************** Destination Preparation ********************* -->
  -
  -  <target name="prepare">
  -    <!-- Set up build directories -->
  -    <mkdir dir="${build.dir}"/>
  -    <mkdir dir="${build.doc}"/>
  -    <mkdir dir="${build.doc}/WEB-INF"/>
  -    <mkdir dir="${build.doc}/WEB-INF/classes"/>
  -    <mkdir dir="${build.doc}/WEB-INF/lib"/>
  -    <mkdir dir="${build.examples}"/>
  -    <mkdir dir="${build.examples}/WEB-INF"/>
  -    <mkdir dir="${build.examples}/WEB-INF/classes"/>
  -    <mkdir dir="${build.examples}/WEB-INF/lib"/>
  -    <mkdir dir="${build.library}"/>
  -    <mkdir dir="${build.library}/META-INF"/>
  -    <!-- Set up distribution directory -->
  -    <mkdir dir="${dist.dir}"/>
  -    <mkdir dir="${dist.dir}/${taglib.name}"/>
  -  </target>
  -
  -
  -  <!-- **************** Compile Tag Library Components ******************** -->
  -
  -  <!-- Compile the documentation application -->
  -  <target name="documentation" depends="prepare">
  -    <copy todir="${build.doc}/WEB-INF">
  -      <fileset dir="${doc.src}/conf"/>
  -    </copy>
  -    <!-- intro.xml isn't part of the documentation application,
  -         this is just a handy place to build it for the web site. -->
  -    <style in="xml/intro.xml"
  -           destdir="${build.doc}"
  -           out="${build.doc}/intro.html"
  -           style="${taglibs.xsl}">
  -      <param name="prefix" expression="../../"/>
  -    </style>
  -    <mkdir dir="${doc.src}/web"/>
  -    <copy todir="${build.doc}">
  -      <fileset dir="${doc.src}/web">
  -        <include name="**/*.html"/>
  -      </fileset>
  -    </copy>
  -  </target>
  -
  -  <!-- Compile the examples application -->
  -  <target name="examples" depends="library-dist">
  -    <copy todir="${build.examples}/WEB-INF">
  -      <fileset dir="${examples.src}/conf"/>
  -    </copy>
  -    <copy todir="${build.examples}">
  -      <fileset dir="${examples.src}/web"/>
  -    </copy>
  -    <copy file="${dist.tld}"
  -              tofile="${build.examples}/WEB-INF/${taglib.name}.tld"/>
  -    <copy file="${dist.library}"
  -              tofile="${build.examples}/WEB-INF/lib/${taglib.name}.jar"/>
  -   <!--
  -    <javac srcdir="${examples.src}/src"
  -           destdir="${build.examples}/WEB-INF/classes"
  -           classpath="${servlet.jar}" debug="on"/>
  -     -->
  -  </target>
  -
  -  <!-- Compile the tag library itself -->
  -  <target name="library" depends="prepare">
  -    <copy file="${conf.src}/taglib.tld"
  -              tofile="${build.library}/META-INF/taglib.tld"/>
  -    <javac srcdir="${library.src}" destdir="${build.library}"
  -           classpath="${servlet.jar}" debug="on"/>
  -  </target>
  -
  -  <!-- Compile the library as well as the associated applications -->
  -  <target name="main" depends="library,documentation,examples"/>
  -
  -
  -  <!-- ******************* Create Distribution Files ********************** -->
  -
  -  <!-- Create the documentation application WAR file -->
  -  <target name="documentation-dist" depends="documentation">
  -    <jar jarfile="${dist.doc}" basedir="${build.doc}" excludes="intro.html"/>
  -    <mkdir dir="${taglibs.doc}"/>
  -    <copy todir="${taglibs.doc}">
  -      <fileset dir="${build.doc}">
  -        <exclude name="WEB-INF"/>     
  -      </fileset>
  -    </copy>
  -  </target>
  -
  -  <!-- Create the examples application WAR file -->
  -  <target name="examples-dist" depends="examples">
  -    <jar jarfile="${dist.examples}" basedir="${build.examples}"/>
  -  </target>
  -
  -  <!-- Create the library distribution files -->
  -  <target name="library-dist" depends="library">
  -    <jar jarfile="${dist.library}" basedir="${build.library}"/>
  -    <copy file="${conf.src}/taglib.tld" tofile="${dist.tld}"/>
  -  </target>
  -
  -  <!-- Create the entire set of distribution files -->
  -  <target name="dist" depends="library-dist,examples-dist,documentation-dist"/>
  -
  -
  -
  -  <!-- ************************ Utility Commands ************************** -->
  -
  -  <!-- Delete output directories and files so we can build from scratch -->
  -  <target name="clean">
  -    <delete dir="${build.dir}/${taglib.name}"/>
  -    <delete dir="${dist.dir}/${taglib.name}"/>
  -  </target>
  +  <property file="../build.properties"/>
  +  <property name="gen-docs.present" value="true"/>
   
  +  &common;
  +
   </project>
  +
  
  
  
  1.2       +7 -0      jakarta-taglibs/benchmark/examples/web/benchmark1.jsp
  
  Index: benchmark1.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/benchmark/examples/web/benchmark1.jsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- benchmark1.jsp	2001/04/26 13:02:39	1.1
  +++ benchmark1.jsp	2001/07/08 16:13:31	1.2
  @@ -1,6 +1,10 @@
   <%@ page session="false" %>
   <%@ taglib uri="http://jakarta.apache.org/taglibs/benchmark" prefix="benchmark" %>
   
  +<html>
  +<body>
  +<p>
  +
   <%-- 
     --
     -- Benchmark example application.  Author: Shawn Bayern
  @@ -53,3 +57,6 @@
      ...
   </benchmark:duration>
   
  +</p>
  +</body>
  +</html>
  
  
  
  1.2       +9 -0      jakarta-taglibs/benchmark/examples/web/benchmark2.jsp
  
  Index: benchmark2.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/benchmark/examples/web/benchmark2.jsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- benchmark2.jsp	2001/04/26 13:02:39	1.1
  +++ benchmark2.jsp	2001/07/08 16:13:31	1.2
  @@ -1,6 +1,10 @@
   <%@ page session="false" %>
   <%@ taglib uri="http://jakarta.apache.org/taglibs/benchmark" prefix="benchmark" %>
   
  +<html>
  +<body>
  +<p>
  +
   <%-- 
     --
     -- Benchmark example application, number two.  Author: Shawn Bayern
  @@ -33,3 +37,8 @@
   <benchmark:duration>
      This body is lost to the ages.
   </benchmark:duration>
  +
  +</p>
  +</body>
  +</html>
  +
  
  
  
  1.1                  jakarta-taglibs/benchmark/xml/intro.xml
  
  Index: intro.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./intro.xml">
  
    <properties>
      <author>Shawn Bayern</author>
      <title>The Jakarta-Taglibs Project: Benchmark Tag Library</title>
    </properties>
  
    <body>
  
  
    <section name="Benchmark Tag Library" href="Welcome">
  
    <p>In dicussions about how best to design tag libraries, issues of
       performance sometimes arise.  The simple 'benchmark' tag library
       should aid in the performance testing of other taglibs and JSP
       pages in general.  This library isn't a full-featured
       benchmarking package.  It's just a simple way to get rough 
       data if you want to sketch the relative performance of tags,
       tag combinations, or arbitrary JSP fragments.</p>
  
    </section>
  
    <section name="Documentation" href="Documentation">
  
    <p>For more information about the Benchmark Tag Library, look at the
       on-line documentation:</p>
    <ul>
    <li>View the <a href="index.html">Benchmark Taglib Documentation</a></li>
    </ul>
  
    <p>For information on how to use the distributions, look at the following documentation:</p>
  
    <ul>
    <li>Using the Jakarta-Taglibs <a href="http://jakarta.apache.org/taglibs/binarydist.html">Binary Distribution</a></li>
    <li>Using the Jakarta-Taglibs <a href="http://jakarta.apache.org/taglibs/sourcedist.html">Source Distribution</a></li>
    </ul>
  
    </section>
  
    <section name="Download" href="Download">
  
    <p>A binary download of the Benchmark Tag Library is available</p>
    <ul>
    <li><strong>Download <a href="http://jakarta.apache.org/builds/jakarta-taglibs/nightly/projects/benchmark/">Benchmark Tag Library</a></strong></li>
    </ul>
  
    <p>The following distributions are also available for download:</p>
    <ul>
    <li>Download <a href="http://jakarta.apache.org/builds/jakarta-taglibs/nightly/src/">Jakarta-Taglibs Source</a></li>
    <li>Download entire <a href="http://jakarta.apache.org/builds/jakarta-taglibs/nightly">Jakarta-Taglibs Distribution</a></li>
    </ul>
  
    </section>
  
    <section name="Contributors" href="Contributors">
    <p>List of contributors:</p>
  
    <ul>
    <li>Shawn Bayern</li>
    </ul>
  
    </section>
  
    </body>
  </document>