kstaken     2002/07/20 19:52:19

  Modified:    .        build.xml
               config   commands.xml system.xml
               docs     README
               java/examples/Addressbook build.xml
               java/examples/Addressbook/src/java/addressbook
                        ListContacts.java
               java/examples/Addressbook/src/jsp error.jsp
               java/src/org/apache/xindice/client/xmldb/xmlrpc
                        CollectionImpl.java DatabaseImpl.java
               java/src/org/apache/xindice/core Collection.java
                        CollectionManager.java Database.java
                        SystemCollection.java
               java/src/org/apache/xindice/core/request URIMapper.java
               java/src/org/apache/xindice/server Xindice.java
               java/src/org/apache/xindice/server/rpc/messages
                        Shutdown.java
               java/src/org/apache/xindice/xml/dom ElementImpl.java
               java/tests/stress build.xml
               java/tests/stress/src AddManyDocuments.java
                        ThrashCollection.java
  Added:       bin      xindice
               java/src/org/apache/xindice/core/data Types.java
                        Variant.java
               java/src/org/apache/xindice/server XindiceServlet.java
  Removed:     .        start startup.bat xindice.server
               bin      .cmdwrapper
               icons    class_mini.gif classes_mini.gif database.gif
                        database_mini.gif databases_mini.gif doc_mini.gif
                        docs_mini.gif file.gif folder.gif folderup.gif
                        group_mini.gif image.gif logo.gif proc_mini.gif
                        procs_mini.gif role_mini.gif roles_mini.gif
                        schema_mini.gif schemas_mini.gif server.gif
                        server_connect.gif server_mini.gif servers_mini.gif
                        spacer.gif text.gif user.gif user_mini.gif
                        users_mini.gif
               java/src/org/apache/xindice/server ComponentManager.java
                        FileManager.java FileResource.java Gateway.java
                        Kernel.java KernelAccess.java LogManager.java
                        ManagerService.java ParameterException.java
                        Persistent.java ResourceManager.java Script.java
                        ScriptComponent.java ScriptFilter.java
                        ScriptManager.java Service.java ServiceManager.java
                        SimpleScript.java SimpleScriptComponent.java
                        Task.java Transient.java User.java UserManager.java
                        VersionProxy.java Versioning.java
               java/src/org/apache/xindice/server/components
                        BasicAuthentication.java DBConduit.java
                        DBQueryResult.java package.html
               java/src/org/apache/xindice/server/methods GET.java PUT.java
                        package.html
               java/src/org/apache/xindice/server/rpc
                        RPCMessageHandler.java
               java/src/org/apache/xindice/server/services HTTPServer.java
                        SocketServer.java XindiceService.java package.html
               java/src/org/apache/xindice/server/standard
                        StdComponentManager.java StdFileManager.java
                        StdLogManager.java StdResourceManager.java
                        StdScriptManager.java StdServiceManager.java
                        StdUserManager.java package.html
               logs     Logs.txt
  Log:
  Stripping the server framework and XMLObjects. There is no longer a standalone
  server version of Xindice. To enable it as a server you have to run it under
  a servlet engine.
  
  Revision  Changes    Path
  1.16      +39 -4     xml-xindice/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/xml-xindice/build.xml,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- build.xml 12 Jul 2002 02:46:10 -0000      1.15
  +++ build.xml 21 Jul 2002 02:52:17 -0000      1.16
  @@ -34,6 +34,11 @@
     <property name="build.dir" value="${root.dir}/classes"/>
     <property name="webapp.dir" value="${root.dir}/webapp"/>
     
  +  <property name="app.name"  value="Xindice"/>
  +  <property name="deploy.home" value="deploy/${app.name}"/>
  +  <property name="class.dir" value="${deploy.home}/WEB-INF/classes"/>
  +  <property name="dist.war" value="${app.name}.war"/>
  +
     <property name="examples.dir" value="${root.dir}/examples"/>
     <property name="examples.build.dir" value="${examples.dir}/classes"/>
     <property name="examples.jarname" value="examples"/>
  @@ -79,9 +84,6 @@
       <property name="distrib.name" value="${name}-${version}"/>
       <property name="jarname" value="xindice"/>
   
  -    <!-- these should really be links but I'm not sure how to get links 
using exec
  -       that don't blow up on windows. Documentation on the os string would 
be nice-->
  -    <copy file="bin/.cmdwrapper" tofile="bin/xindice"/>
       <chmod file="bin/xindice" perm="+x"/>
     </target>
   
  @@ -114,6 +116,39 @@
              />
     </target>
   
  +  <!-- =================================================================== 
-->
  +  <!-- Build the Xindice War                                               
-->
  +  <!-- =================================================================== 
-->
  +   <target name="prepare-war">
  +      <echo message="Creating directory structure under ${deploy.home}"/>
  +      <mkdir dir="${deploy.home}"/>
  +      <mkdir dir="${deploy.home}/images"/>
  +      <mkdir dir="${deploy.home}/WEB-INF/lib"/>
  +   </target>
  +
  +   <!-- Build the War file -->
  +   <target name="war" depends="compile">
  +      <echo message="Creating file ./${dist.war}"/>
  +
  +      <copy file="${jar.dir}/xindice.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xmldb-api-20020712.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xmldb-xupdate.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/infozone-tools.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xmldb-sdk.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xalan-2.3.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xerces-2.0.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xmlrpc-1.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="${jar.dir}/xml-apis-1.0.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="config/web.xml" tofile="${deploy.home}/WEB-INF/web.xml"/>
  +      <jar jarfile="./${dist.war}" basedir="${deploy.home}"/>
  +   </target>
  +   
  +   <!-- Remove the deployment home directory structure -->
  +   <target name="clean-war">
  +      <echo message="Removing directory tree under ${deploy.home}"/>
  +      <delete dir="${deploy.home}"/>
  +      <delete file="${dist.war}" />
  +   </target>
   
     <target name="scratchpad" depends="prepare, clean-jar, src, 
scratchpad-src, bin-jar">
     </target>
  
  
  
  1.1                  xml-xindice/bin/xindice
  
  Index: xindice
  ===================================================================
  #!/bin/sh
  
  if test -z "$XINDICE_HOME"; then
     echo "\$XINDICE_HOME Is Not Set"
     exit
  fi
  
  CMD_HOME=`dirname $0`
  CMD_NAME=`basename $0`
  
  CLASSPATH=$XINDICE_HOME/classgen:$XINDICE_HOME/config:$CLASSPATH
  
  # Read in the list of Xindice Jars to include in the CLASSPATH
  JARS=`ls -1 $XINDICE_HOME/java/lib/*.jar`
  JAR_LIST=""
  for jar in $JARS ; do
     JAR_LIST="$JAR_LIST `basename $jar`"
     CLASSPATH=$jar:$CLASSPATH ;
  done
  
  # Read in the extra VM paramters for starting the program
  VMPROPS=""
  if test -f $XINDICE_HOME/config/vm.cfg; then
     PROPS="`cat $XINDICE_HOME/config/vm.cfg`"
     for prop in $PROPS
     do
        VMPROPS="$VMPROPS $prop"
     done
  fi
  
  case $CMD_NAME in
     xindice)       CLASS_NAME="org.apache.xindice.tools.XMLTools" ;;
     *)           echo "Error mapping command link to Java class"
                  exit 1 ;;
  esac
  
  $JAVA_HOME/bin/java -Xms16m -Xmx128m -Dxindice.home="$XINDICE_HOME" 
-Dcmd.home="$CMD_HOME" $VMPROPS -classpath "$CLASSPATH" $CLASS_NAME $*
  
  
  
  1.3       +1 -21     xml-xindice/config/commands.xml
  
  Index: commands.xml
  ===================================================================
  RCS file: /home/cvs/xml-xindice/config/commands.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- commands.xml      11 Jul 2002 04:37:02 -0000      1.2
  +++ commands.xml      21 Jul 2002 02:52:17 -0000      1.3
  @@ -26,16 +26,6 @@
                  class="org.apache.xindice.tools.command.ImportTree"
                  helpclass="document"
                  description="Creates a collection/document from a directory 
tree" />
  -      <command switch="ao"
  -               name="add_xmlobject"
  -               
class="org.apache.xindice.tools.command.AddCollectionXMLObject"
  -               helpclass="document"
  -               description="Adds an XMLObject to the collection" />
  -      <command switch="do"
  -               name="delete_xmlobject"
  -               
class="org.apache.xindice.tools.command.DeleteCollectionXMLObject"
  -               helpclass="document"
  -               description="Deletes an XMLObject from a collection" />
         <command switch="di"
                  name="delete_indexer"
                  class="org.apache.xindice.tools.command.DeleteIndexer"
  @@ -86,16 +76,6 @@
                  
class="org.apache.xindice.tools.command.ListCollectionDocuments"
                  helpclass="document"
                  description="Retrieves a list of documents in a particular 
collection" />
  -      <command switch="invoke"
  -               name="invoke_xmlobject"
  -               class="org.apache.xindice.tools.command.InvokeXmlObject"
  -               helpclass="document"
  -               description="Invokes an XML Object on a collection" />
  -      <command switch="lo"
  -               name="list_xmlobjects"
  -               
class="org.apache.xindice.tools.command.ListCollectionXMLObjects"
  -               helpclass="document"
  -               description="Retrieves an XMLObject list from a collection" />
         <command switch="xpath"
                  name="xpath_query"
                  class="org.apache.xindice.tools.command.XPathQuery"
  
  
  
  1.7       +7 -190    xml-xindice/config/system.xml
  
  Index: system.xml
  ===================================================================
  RCS file: /home/cvs/xml-xindice/config/system.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- system.xml        12 Jul 2002 02:46:10 -0000      1.6
  +++ system.xml        21 Jul 2002 02:52:17 -0000      1.7
  @@ -1,192 +1,9 @@
   <?xml version="1.0"?>
  -<xindice xsi="http://www.w3.org/1999/XMLSchema-instance"; 
noNamespaceSchemaLocation="../xml/system.xsd">
  -<!--
  -NOTE: Modifying this file by hand while the server is running will
  -      require a server restart in order to allow any changes to take
  -      effect.  Whenever possible, the Command-line tools are the
  -      preferable way to change the system configuration.
  --->
  -   <server gcinterval="0">
  -
  -      <services class="org.apache.xindice.server.standard.StdServiceManager">
  -         <service class="org.apache.xindice.server.services.XindiceService" 
name="Xindice">
  -            <root-collection dbroot="./db/" name="db" security="false">
  -               <queryengine>
  -                  <resolver autoindex="false" 
class="org.apache.xindice.core.query.XPathQueryResolver" />
  -                  <resolver 
class="org.apache.xindice.core.xupdate.XUpdateQueryResolver" />
  -               </queryengine>
  -            </root-collection>
  -         </service>
  -         <service class="org.apache.xindice.server.services.HTTPServer" 
docroot="./docs/" name="HTTPServer">
  -            <bind chunksize="32768" host="" keepalive="16" linger="1000" 
port="4080" reverse="no" timeout="300" />
  -            <aliases>
  -               <alias name="icons" path="./icons" />
  -               <alias name="doc" path="./docs" />
  -               <alias name="javadoc" path="./java/docs/api" />
  -               <alias name="scripts" path="./scripts" />
  -            </aliases>
  -            <methods>
  -               <method command="OPTIONS" script="OPTIONS" />
  -               <method command="GET" script="GET" />
  -               <method command="HEAD" script="GET" />
  -               <method command="POST" script="GET" />
  -               <method command="PUT" script="PUT" />
  -               <method command="DELETE" script="DELETE" />
  -               <method command="TRACE" script="TRACE" />
  -            </methods>
  -            <responses>
  -               <response code="100" message="Continue" />
  -               <response code="101" message="Switching Protocols" />
  -               <response code="200" message="OK" />
  -               <response code="201" message="Created" />
  -               <response code="202" message="Accepted" />
  -               <response code="203" message="Non-Authoritative Information" 
/>
  -               <response code="204" message="No Content" />
  -               <response code="205" message="Reset Content" />
  -               <response code="206" message="Partial Content" />
  -               <response code="300" message="Multiple Choices" />
  -               <response code="301" message="Moved Permanently" />
  -               <response code="302" message="Found" />
  -               <response code="303" message="See Other" />
  -               <response code="304" message="Not Modified" />
  -               <response code="305" message="Use Proxy" />
  -               <response code="307" message="Temporary Redirect" />
  -               <response code="400" message="Bad Request" />
  -               <response code="401" message="Unauthorized" />
  -               <response code="402" message="Payment Required" />
  -               <response code="403" message="Forbidden" />
  -               <response code="404" message="Not Found" />
  -               <response code="405" message="Method Not Allowed" />
  -               <response code="406" message="Not Acceptable" />
  -               <response code="407" message="Proxy Authentication Required" 
/>
  -               <response code="408" message="Request Timeout" />
  -               <response code="409" message="Conflict" />
  -               <response code="410" message="Gone" />
  -               <response code="411" message="Length Required" />
  -               <response code="412" message="Precondition Failed" />
  -               <response code="413" message="Request Entity Too Large" />
  -               <response code="414" message="Request-URI Too Long" />
  -               <response code="415" message="Unsupported Media Type" />
  -               <response code="416" message="Request Range Not Satisfiable" 
/>
  -               <response code="417" message="Expectation Failed" />
  -               <response code="500" message="Internal Server Error" />
  -               <response code="501" message="Not Implemented" />
  -               <response code="502" message="Bad Gateway" />
  -               <response code="503" message="Service Unavailable" />
  -               <response code="504" message="Gateway Timeout" />
  -               <response code="505" message="HTTP Version not supported" />
  -            </responses>
  -         </service>
  -      </services>
  -
  -      <logging class="org.apache.xindice.server.standard.StdLogManager" 
filename="./logs/Xindice.log" rotate="yes" />
  -      <resources 
class="org.apache.xindice.server.standard.StdResourceManager" vulture="20" />
  -      <files chunksize="32768" 
class="org.apache.xindice.server.standard.StdFileManager" maxbytes="131072" 
minbytes="0" tmpdir="./tmp/" />
  -      <components 
class="org.apache.xindice.server.standard.StdComponentManager">
  -         <component class="org.apache.xindice.server.rpc.RPCMessageHandler" 
name="RPCHandler"/>
  -         <component browse="yes" 
class="org.apache.xindice.server.methods.GET" defaulticon="/icons/file.gif" 
foldericon="/icons/folder.gif" folderupicon="/icons/folderup.gif" 
index="index.html" name="GET" spacericon="/icons/spacer.gif">
  -            <icons>
  -               <icon ext="txt" path="/icons/text.gif" />
  -               <icon ext="bmp" path="/icons/image.gif" />
  -               <icon ext="jpg" path="/icons/image.gif" />
  -               <icon ext="jpeg" path="/icons/image.gif" />
  -               <icon ext="gif" path="/icons/image.gif" />
  -               <icon ext="png" path="/icons/image.gif" />
  -            </icons>
  -         </component>
  -      </components>
  -      <scripts class="org.apache.xindice.server.standard.StdScriptManager" 
exceptions="yes" scriptdir="./scripts/" stablescripts="yes" />
  -   </server>
  -
  -   <common>
  -      <corba class="org.openorb.CORBA.ORB" 
singletonclass="org.openorb.CORBA.ORBSingleton" />
  -      <mime default="text/plain">
  -         <mimetype ext="ez" type="application/andrew-inset" />
  -         <mimetype ext="hqx" type="application/mac-binhex40" />
  -         <mimetype ext="cpt" type="application/mac-compactpro" />
  -         <mimetype ext="doc" type="application/msword" />
  -         <mimetype ext="bin dms lha lzh exe class" 
type="application/octet-stream" />
  -         <mimetype ext="oda" type="application/oda" />
  -         <mimetype ext="pdf" type="application/pdf" />
  -         <mimetype ext="ai eps ps" type="application/postscript" />
  -         <mimetype ext="rtf" type="application/rtf" />
  -         <mimetype ext="smi smil" type="application/smil" />
  -         <mimetype ext="mif" type="application/vnd.mif" />
  -         <mimetype ext="xls" type="application/vnd.ms-excel" />
  -         <mimetype ext="ppt" type="application/vnd.ms-powerpoint" />
  -         <mimetype ext="bcpio" type="application/x-bcpio" />
  -         <mimetype ext="vcd" type="application/x-cdlink" />
  -         <mimetype ext="pgn" type="application/x-chess-pgn" />
  -         <mimetype ext="cpio" type="application/x-cpio" />
  -         <mimetype ext="csh" type="application/x-csh" />
  -         <mimetype ext="dcr dir dxr" type="application/x-director" />
  -         <mimetype ext="dvi" type="application/x-dvi" />
  -         <mimetype ext="spl" type="application/x-futuresplash" />
  -         <mimetype ext="gtar" type="application/x-gtar" />
  -         <mimetype ext="gz" type="application/x-gzip" />
  -         <mimetype ext="hdf" type="application/x-hdf" />
  -         <mimetype ext="js" type="application/x-javascript" />
  -         <mimetype ext="skp skd skt skm" type="application/x-koan" />
  -         <mimetype ext="latex" type="application/x-latex" />
  -         <mimetype ext="nc cdf" type="application/x-netcdf" />
  -         <mimetype ext="sh" type="application/x-sh" />
  -         <mimetype ext="shar" type="application/x-shar" />
  -         <mimetype ext="swf" type="application/x-shockwave-flash" />
  -         <mimetype ext="sit" type="application/x-stuffit" />
  -         <mimetype ext="sv4cpio" type="application/x-sv4cpio" />
  -         <mimetype ext="sv4crc" type="application/x-sv4crc" />
  -         <mimetype ext="tar" type="application/x-tar" />
  -         <mimetype ext="tcl" type="application/x-tcl" />
  -         <mimetype ext="tex" type="application/x-tex" />
  -         <mimetype ext="texinfo texi" type="application/x-texinfo" />
  -         <mimetype ext="t tr roff" type="application/x-troff" />
  -         <mimetype ext="man" type="application/x-troff-man" />
  -         <mimetype ext="me" type="application/x-troff-me" />
  -         <mimetype ext="ms" type="application/x-troff-ms" />
  -         <mimetype ext="ustar" type="application/x-ustar" />
  -         <mimetype ext="src" type="application/x-wais-source" />
  -         <mimetype ext="zip" type="application/zip" />
  -         <mimetype ext="au snd" type="audio/basic" />
  -         <mimetype ext="mid midi kar" type="audio/midi" />
  -         <mimetype ext="mpga mp2 mp3" type="audio/mpeg" />
  -         <mimetype ext="aif aiff aifc" type="audio/x-aiff" />
  -         <mimetype ext="ram rm" type="audio/x-pn-realaudio" />
  -         <mimetype ext="rpm" type="audio/x-pn-realaudio-plugin" />
  -         <mimetype ext="ra" type="audio/x-realaudio" />
  -         <mimetype ext="wav" type="audio/x-wav" />
  -         <mimetype ext="pdb xyz" type="chemical/x-pdb" />
  -         <mimetype ext="bmp" type="image/bmp" />
  -         <mimetype ext="gif" type="image/gif" />
  -         <mimetype ext="ief" type="image/ief" />
  -         <mimetype ext="jpeg jpg jpe" type="image/jpeg" />
  -         <mimetype ext="png" type="image/png" />
  -         <mimetype ext="tiff tif" type="image/tiff" />
  -         <mimetype ext="ras" type="image/x-cmu-raster" />
  -         <mimetype ext="pnm" type="image/x-portable-anymap" />
  -         <mimetype ext="pbm" type="image/x-portable-bitmap" />
  -         <mimetype ext="pgm" type="image/x-portable-graymap" />
  -         <mimetype ext="ppm" type="image/x-portable-pixmap" />
  -         <mimetype ext="rgb" type="image/x-rgb" />
  -         <mimetype ext="xbm" type="image/x-xbitmap" />
  -         <mimetype ext="xpm" type="image/x-xpixmap" />
  -         <mimetype ext="xwd" type="image/x-xwindowdump" />
  -         <mimetype ext="igs iges" type="model/iges" />
  -         <mimetype ext="msh mesh silo" type="model/mesh" />
  -         <mimetype ext="wrl vrml" type="model/vrml" />
  -         <mimetype ext="css" type="text/css" />
  -         <mimetype ext="html htm" type="text/html" />
  -         <mimetype ext="asc txt" type="text/plain" />
  -         <mimetype ext="rtx" type="text/richtext" />
  -         <mimetype ext="rtf" type="text/rtf" />
  -         <mimetype ext="sgml sgm" type="text/sgml" />
  -         <mimetype ext="tsv" type="text/tab-separated-values" />
  -         <mimetype ext="etx" type="text/x-setext" />
  -         <mimetype ext="xml xsl" type="text/xml" />
  -         <mimetype ext="mpeg mpg mpe" type="video/mpeg" />
  -         <mimetype ext="qt mov" type="video/quicktime" />
  -         <mimetype ext="avi" type="video/x-msvideo" />
  -         <mimetype ext="movie" type="video/x-sgi-movie" />
  -         <mimetype ext="ice" type="x-conference/x-cooltalk" />
  -      </mime>
  -   </common>
  +<xindice>
  +   <root-collection dbroot="./db/" name="db">
  +      <queryengine>
  +         <resolver autoindex="false" 
class="org.apache.xindice.core.query.XPathQueryResolver" />
  +         <resolver 
class="org.apache.xindice.core.xupdate.XUpdateQueryResolver" />
  +      </queryengine>
  +   </root-collection>
   </xindice>
  
  
  
  1.7       +4 -0      xml-xindice/docs/README
  
  Index: README
  ===================================================================
  RCS file: /home/cvs/xml-xindice/docs/README,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- README    19 Jul 2002 03:29:13 -0000      1.6
  +++ README    21 Jul 2002 02:52:17 -0000      1.7
  @@ -76,6 +76,10 @@
     has been removed. Along with this the -y option that would force
     automatic deletion has also been removed.
   
  +- The command line tools can be run against a network version of
  +  Xindice or against a local database. See the -l and -d options
  +  to learn more about local database access.
  +
   - XMLObjects have been removed.
   
   Apache Xindice Version 1.0
  
  
  
  1.3       +5 -3      xml-xindice/java/examples/Addressbook/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/xml-xindice/java/examples/Addressbook/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- build.xml 5 Feb 2002 07:30:52 -0000       1.2
  +++ build.xml 21 Jul 2002 02:52:17 -0000      1.3
  @@ -35,10 +35,12 @@
            <fileset dir="./src/jsp" includes="**/*.jsp"/>
         </copy>
         <copy file="../../lib/xindice.jar" todir="${deploy.home}/WEB-INF/lib"/>
  -      <copy file="../../lib/xmldb.jar" todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="../../lib/xmldb-api-20020712.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
         <copy file="../../lib/xmldb-sdk.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  -      <copy file="../../lib/xalan-2.0.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  -      <copy file="../../lib/xerces-1.4.3.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="../../lib/xalan-2.3.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="../../lib/xerces-2.0.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="../../lib/xmlrpc-1.1.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
  +      <copy file="../../lib/xml-apis-1.0.jar" 
todir="${deploy.home}/WEB-INF/lib"/>
         <copy file="web.xml" tofile="${deploy.home}/WEB-INF/web.xml"/>
      </target>
      
  
  
  
  1.3       +2 -2      
xml-xindice/java/examples/Addressbook/src/java/addressbook/ListContacts.java
  
  Index: ListContacts.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/examples/Addressbook/src/java/addressbook/ListContacts.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ListContacts.java 11 Mar 2002 22:32:35 -0000      1.2
  +++ ListContacts.java 21 Jul 2002 02:52:17 -0000      1.3
  @@ -106,7 +106,7 @@
          // there's not much else we can do if the response is committed
          if (response.isCommitted())
             return true;
  -
  +e.printStackTrace();
            // Catch the exception and send the user to the error page
            if (e.getMessage() != null ) {
               response.sendRedirect("/Addressbook/error.jsp?error=" + 
URLEncoder.encode(e.getMessage()) );
  
  
  
  1.2       +2 -2      xml-xindice/java/examples/Addressbook/src/jsp/error.jsp
  
  Index: error.jsp
  ===================================================================
  RCS file: /home/cvs/xml-xindice/java/examples/Addressbook/src/jsp/error.jsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- error.jsp 6 Dec 2001 19:33:52 -0000       1.1
  +++ error.jsp 21 Jul 2002 02:52:17 -0000      1.2
  @@ -61,7 +61,7 @@
   
   <%@ include file="header.jsp" %>
   
  -   <FONT SIZE="+5">
  +   <FONT SIZE="+1">
         <CENTER>
            <FONT COLOR="RED">An ERROR has occured!!!</FONT>
            <BR>
  
  
  
  1.9       +2 -2      
xml-xindice/java/src/org/apache/xindice/client/xmldb/xmlrpc/CollectionImpl.java
  
  Index: CollectionImpl.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/client/xmldb/xmlrpc/CollectionImpl.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- CollectionImpl.java       20 Jul 2002 22:44:36 -0000      1.8
  +++ CollectionImpl.java       21 Jul 2002 02:52:17 -0000      1.9
  @@ -90,7 +90,7 @@
    */
   public class CollectionImpl extends XindiceCollection {          
       /* path to XML-RPC service on database */
  -    private static String XINDICE_SERVICE_LOCATION = "/RPC2";
  +    private static String XINDICE_SERVICE_LOCATION = "/Xindice";
   
       /* host and port number of server */
       private String hostPort;
  
  
  
  1.3       +2 -2      
xml-xindice/java/src/org/apache/xindice/client/xmldb/xmlrpc/DatabaseImpl.java
  
  Index: DatabaseImpl.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/client/xmldb/xmlrpc/DatabaseImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseImpl.java 11 Jul 2002 23:25:28 -0000      1.2
  +++ DatabaseImpl.java 21 Jul 2002 02:52:17 -0000      1.3
  @@ -137,7 +137,7 @@
           /* Absent host defaults to localhost and standard Xindice HTTP port 
*/
           if (hostPort.equals("")) {
   
  -            hostPort = "127.0.0.1:4080";
  +            hostPort = "127.0.0.1:8080";
           }
           
           return new CollectionImpl(hostPort, collPath);
  
  
  
  1.4       +1 -78     
xml-xindice/java/src/org/apache/xindice/core/Collection.java
  
  Index: Collection.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/core/Collection.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Collection.java   19 Jul 2002 03:38:42 -0000      1.3
  +++ Collection.java   21 Jul 2002 02:52:17 -0000      1.4
  @@ -61,7 +61,6 @@
   
   import org.apache.xindice.xml.*;
   import org.apache.xindice.xml.dom.*;
  -import org.apache.xindice.core.objects.*;
   import org.apache.xindice.core.data.*;
   import org.apache.xindice.core.filer.*;
   import org.apache.xindice.core.indexer.*;
  @@ -88,7 +87,6 @@
      private static final String INDEXES = "indexes";
      private static final String COMPRESSED = "compressed";
      private static final String CACHE = "cache";
  -   private static final String XMLOBJECTS = "xmlobjects";
      private static final String DOCUMENTS = "documents";
      private static final String SYMBOLS = "symbols";
      private static final String CLASSNAME = "xindice-class";
  @@ -130,7 +128,6 @@
      private boolean internalSymbols = false;
   
      private IndexManager indexManager;
  -   private XMLObjectManager xmlObjects;
      private DocumentCache documentCache;
   
      protected Collection() {
  @@ -202,16 +199,6 @@
               org.apache.xindice.Debug.printStackTrace(e);
            }
         }
  -
  -      // XMLObject Manager
  -      xmlObjects = new XMLObjectManager(this);
  -      try {
  -         Configuration objConfig = config.getChild(XMLOBJECTS, true);
  -         xmlObjects.setConfig(objConfig);
  -      }
  -      catch ( Exception e ) {
  -         org.apache.xindice.Debug.printStackTrace(e);
  -      }
         
         super.setConfig(config);
   
  @@ -363,65 +350,6 @@
         return indexManager;
      }
   
  -   
  -   /**
  -    * getXMLObjectManager returns the Object's XMLObjectManager.
  -    *
  -    * @return The XMLObjectManager
  -    */
  -   public final XMLObjectManager getXMLObjectManager() throws DBException {
  -      return xmlObjects;
  -   }
  -   
  -   /**
  -    * getXMLObject retrieves an XMLObject by name.
  -    *
  -    * @param name The XMLObject's name
  -    * @return The XMLObject (or null)
  -    */
  -   public final XMLObject getXMLObject(String name) throws DBException {
  -      return xmlObjects.get(name);
  -   }
  -
  -   /**
  -    * listXMLObjects returns a list of the currently registered XMLObjects
  -    * as an array of String.
  -    *
  -    * @return The XMLObject list
  -    */
  -   public String[] listXMLObjects() throws DBException {
  -      return xmlObjects.list();
  -   }
  -
  -   /**
  -    * dropXMLObject physically removes the specified XMLObject and any
  -    * associated system resources that the XMLObject uses.
  -    *
  -    * @param xmlObject The XMLObject to drop
  -    * @return Whether or not the XMLObject was dropped
  -    */
  -   public final boolean dropXMLObject(XMLObject xmlObject) throws 
DBException {
  -      if ( xmlObject == null )
  -         throw new DBException(FaultCodes.OBJ_OBJECT_NOT_FOUND, "Object 
Value Null");
  -      
  -      boolean success = xmlObjects.drop(xmlObject.getName());
  -      getDatabase().flushConfig();
  -      return success;
  -   }
  -
  -   /**
  -    * createXMLObject creates a new XMLObject object and any associated
  -    * system resources that the XMLObject will need.
  -    *
  -    * @param config The XMLObject's configuration
  -    * @return The newly created XMLObject
  -    */
  -   public final XMLObject createXMLObject(Configuration config) throws 
DBException {
  -      XMLObject obj = xmlObjects.create(config);
  -      getDatabase().flushConfig();
  -      return obj;
  -   }
  -
      /**
       * getSymbols returns the SymbolTable in use by this
       * Collection.
  @@ -530,11 +458,6 @@
         for ( int i = 0; i < cols.length; i++ )
            dropCollection(getCollection(cols[i]));
         
  -      // Drop XMLObjects
  -      String[] objs = listXMLObjects();
  -      for ( int i = 0; i < objs.length; i++ )
  -         dropXMLObject(getXMLObject(objs[i]));
  -
         if ( filer != null ) {
            // Drop Indexers
            String[] idx = indexManager.list();
  
  
  
  1.4       +1 -2      
xml-xindice/java/src/org/apache/xindice/core/CollectionManager.java
  
  Index: CollectionManager.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/core/CollectionManager.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- CollectionManager.java    10 Jul 2002 08:55:56 -0000      1.3
  +++ CollectionManager.java    21 Jul 2002 02:52:17 -0000      1.4
  @@ -59,7 +59,6 @@
    * $Id$
    */
   
  -import org.apache.xindice.core.objects.*;
   import org.apache.xindice.core.Collection;
   import org.apache.xindice.util.*;
   
  
  
  
  1.6       +1 -2      
xml-xindice/java/src/org/apache/xindice/core/Database.java
  
  Index: Database.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/core/Database.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Database.java     19 Jul 2002 03:38:42 -0000      1.5
  +++ Database.java     21 Jul 2002 02:52:17 -0000      1.6
  @@ -60,7 +60,6 @@
    */
   
   import org.apache.xindice.core.query.*;
  -import org.apache.xindice.core.objects.*;
   import org.apache.xindice.core.request.*;
   import org.apache.xindice.util.*;
   
  
  
  
  1.4       +1 -2      
xml-xindice/java/src/org/apache/xindice/core/SystemCollection.java
  
  Index: SystemCollection.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/core/SystemCollection.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- SystemCollection.java     25 Feb 2002 23:42:54 -0000      1.3
  +++ SystemCollection.java     21 Jul 2002 02:52:17 -0000      1.4
  @@ -62,7 +62,6 @@
   import org.apache.xindice.core.*;
   import org.apache.xindice.core.Collection;
   import org.apache.xindice.server.*;
  -import org.apache.xindice.core.objects.*;
   import org.apache.xindice.xml.*;
   import org.apache.xindice.xml.dom.*;
   import org.apache.xindice.tools.*;
  
  
  
  1.1                  
xml-xindice/java/src/org/apache/xindice/core/data/Types.java
  
  Index: Types.java
  ===================================================================
  package org.apache.xindice.core.data;
  
  /*
   * The Apache Software License, Version 1.1
   *
   *
   * Copyright (c) 1999 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *    notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *    notice, this list of conditions and the following disclaimer in
   *    the documentation and/or other materials provided with the
   *    distribution.
   *
   * 3. The end-user documentation included with the redistribution,
   *    if any, must include the following acknowledgment:
   *       "This product includes software developed by the
   *        Apache Software Foundation (http://www.apache.org/)."
   *    Alternately, this acknowledgment may appear in the software itself,
   *    if and wherever such third-party acknowledgments normally appear.
   *
   * 4. The names "Xindice" and "Apache Software Foundation" must
   *    not be used to endorse or promote products derived from this
   *    software without prior written permission. For written
   *    permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called "Apache",
   *    nor may "Apache" appear in their name, without prior written
   *    permission of the Apache Software Foundation.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * ====================================================================
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation and was
   * originally based on software copyright (c) 1999-2001, The dbXML
   * Group, L.L.C., http://www.dbxmlgroup.com.  For more
   * information on the Apache Software Foundation, please see
   * <http://www.apache.org/>.
   *
   * $Id: Types.java,v 1.1 2002/07/21 02:52:18 kstaken Exp $
   */
  
  import org.w3c.dom.*;
  import org.apache.xindice.core.*;
  
  /**
   * Types defines identifying values for the types that Xindice Reflectable
   * methods support.
   */
  
  public final class Types {
     public final static int EMPTY = -1;
     public final static int UNKNOWN = -1;
     public final static int VOID = 0;
     public final static int BOOLEAN = 1;
     public final static int BYTE = 2;
     public final static int CHAR = 3;
     public final static int SHORT = 4;
     public final static int INT = 5;
     public final static int LONG = 6;
     public final static int FLOAT = 7;
     public final static int DOUBLE = 8;
     public final static int OBJECT = 10;
     public final static int STRING = 11;
     public final static int ELEMENT = 12;
     public final static int DOCUMENT = 13;
     public final static int DOCUMENTFRAGMENT = 14;
     public final static int ARGS = 15;
     public final static int VARIANT = 20;
  
     private Types() {
     }
  
     /**
      * TypeOf inspects the Class, and returns the type value for that Class
      * or UNKNOWN, if the Class is not an acceptable signature type.
      *
      * @param c The Class to check
      * @return The type value
      */
     public static int typeOf(Class c) {
        if( c.isArray() )
           c = c.getComponentType();
  
        if ( c == void.class )
           return VOID;
  
        if ( c.isPrimitive() ) {
           if ( c == Boolean.TYPE )
              return BOOLEAN;
           else if ( c == Byte.TYPE )
              return BYTE;
           else if ( c == Character.TYPE )
              return CHAR;
           else if ( c  == Short.TYPE )
              return SHORT;
           else if ( c == Integer.TYPE )
              return INT;
           else if ( c == Long.TYPE )
              return LONG;
           else if ( c == Float.TYPE )
              return FLOAT;
           else if ( c == Double.TYPE )
              return DOUBLE;
        }
        else {
           if ( c == String.class )
              return STRING;
           else if ( c == Variant.class )
              return VARIANT;
           else if ( Element.class.isAssignableFrom(c) )
              return ELEMENT;
           else if ( Document.class.isAssignableFrom(c) )
              return DOCUMENT;
           else if ( DocumentFragment.class.isAssignableFrom(c) )
              return DOCUMENTFRAGMENT;
        }
        return UNKNOWN;
     }
  
     public static int typeOf(Object object) {
        return object != null ? typeOf(object.getClass())
                              : EMPTY;
     }
  
     public static String typeName(int type) {
        switch ( type ) {
  
           case UNKNOWN          : return "Unknown";
           case VOID             : return "void";
           case BOOLEAN          : return "boolean";
           case BYTE             : return "byte";
           case CHAR             : return "char";
           case SHORT            : return "short";
           case INT              : return "int";
           case LONG             : return "long";
           case FLOAT            : return "float";
           case DOUBLE           : return "double";
           case OBJECT           : return "Object";
           case STRING           : return "String";
           case ELEMENT          : return "Element";
           case DOCUMENT         : return "Document";
           case DOCUMENTFRAGMENT : return "DocumentFragment";
           case ARGS             : return "Args";
           case VARIANT          : return "Variant";
  
        }
        return "Invalid";
     }
  }
  
  
  
  
  1.1                  
xml-xindice/java/src/org/apache/xindice/core/data/Variant.java
  
  Index: Variant.java
  ===================================================================
  package org.apache.xindice.core.data;
  
  /*
   * The Apache Software License, Version 1.1
   *
   *
   * Copyright (c) 1999 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *    notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *    notice, this list of conditions and the following disclaimer in
   *    the documentation and/or other materials provided with the
   *    distribution.
   *
   * 3. The end-user documentation included with the redistribution,
   *    if any, must include the following acknowledgment:
   *       "This product includes software developed by the
   *        Apache Software Foundation (http://www.apache.org/)."
   *    Alternately, this acknowledgment may appear in the software itself,
   *    if and wherever such third-party acknowledgments normally appear.
   *
   * 4. The names "Xindice" and "Apache Software Foundation" must
   *    not be used to endorse or promote products derived from this
   *    software without prior written permission. For written
   *    permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called "Apache",
   *    nor may "Apache" appear in their name, without prior written
   *    permission of the Apache Software Foundation.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * ====================================================================
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation and was
   * originally based on software copyright (c) 1999-2001, The dbXML
   * Group, L.L.C., http://www.dbxmlgroup.com.  For more
   * information on the Apache Software Foundation, please see
   * <http://www.apache.org/>.
   *
   * $Id: Variant.java,v 1.1 2002/07/21 02:52:18 kstaken Exp $
   */
  
  import org.apache.xindice.core.*;
  import org.apache.xindice.xml.*;
  import org.apache.xindice.util.*;
  
  import org.w3c.dom.*;
  
  /**
   * Variant is a generic type that can be used to store any type of Xindice
   * variable.  Variants will do their best to convert the value that they
   * store to any requested type.
   */
  
  public final class Variant {
     private Object value = null;
     private int type = -1;
  
     public Variant() {
     }
  
     public Variant(Variant value) {
        this.value = value.value;
        type = value.type;
     }
  
     public Variant(String value) {
        this.value = value;
        type = Types.STRING;
     }
  
     public Variant(boolean value) {
        this.value = new Boolean(value);
        type = Types.BOOLEAN;
     }
  
     public Variant(byte value) {
        this.value = new Byte(value);
        type = Types.BYTE;
     }
  
     public Variant(char value) {
        this.value = new Character(value);
        type = Types.CHAR;
     }
  
     public Variant(short value) {
        this.value = new Short(value);
        type = Types.SHORT;
     }
  
     public Variant(int value) {
        this.value = new Integer(value);
        type = Types.INT;
     }
  
     public Variant(long value) {
        this.value = new Long(value);
        type = Types.LONG;
     }
  
     public Variant(float value) {
        this.value = new Float(value);
        type = Types.FLOAT;
     }
  
     public Variant(double value) {
        this.value = new Double(value);
        type = Types.DOUBLE;
     }
  
     public Variant(Element value) {
        this.value = value;
        type = Types.ELEMENT;
     }
  
     public Variant(Document value) {
        this.value = value;
        type = Types.DOCUMENT;
     }
  
     public Variant(DocumentFragment value) {
        this.value = value;
        type = Types.DOCUMENTFRAGMENT;
     }
  
     public Variant(Object value) {
        this.value = value;
        type = Types.OBJECT;
     }
  
     /**
      * getType returns the type of the variable being stored in the Variant.
      *
      * @return The variable type
      */
     public int getType() {
        return type;
     }
  
     /**
      * isNull returns whether or not the variable is storing a null value.
      */
     public boolean isNull() {
        return value == null;
     }
  
     /**
      * set sets the value as a String.
      *
      * @param value The value
      */
     public void set(String value) {
        this.value = value;
        type = Types.STRING;
     }
  
     /**
      * set sets the value as a boolean.
      *
      * @param value The value
      */
     public void set(boolean value) {
        this.value = new Boolean(value);
        type = Types.BOOLEAN;
     }
  
     /**
      * set sets the value as a byte.
      *
      * @param value The value
      */
     public void set(byte value) {
        this.value = new Byte(value);
        type = Types.BYTE;
     }
  
     /**
      * set sets the value as a char.
      *
      * @param value The value
      */
     public void set(char value) {
        this.value = new Character(value);
        type = Types.CHAR;
     }
  
     /**
      * set sets the value as a short
      *
      * @param value The value
      */
     public void set(short value) {
        this.value = new Short(value);
        type = Types.SHORT;
     }
  
     /**
      * set sets the value as an int.
      *
      * @param value The value
      */
     public void set(int value) {
        this.value = new Integer(value);
        type = Types.INT;
     }
  
     /**
      * set sets the value as a long.
      *
      * @param value The value
      */
     public void set(long value) {
        this.value = new Long(value);
        type = Types.LONG;
     }
  
     /**
      * set sets the value as a float.
      *
      * @param value The value
      */
     public void set(float value) {
        this.value = new Float(value);
        type = Types.FLOAT;
     }
  
     /**
      * set sets the value as a double.
      *
      * @param value The value
      */
     public void set(double value) {
        this.value = new Double(value);
        type = Types.DOUBLE;
     }
  
     /**
      * set sets the value as an Element.
      *
      * @param value The value
      */
     public void set(Element value) {
        this.value = value;
        type = Types.ELEMENT;
     }
  
     /**
      * set sets the value as a Document.
      *
      * @param value The value
      */
     public void set(Document value) {
        this.value = value;
        type = Types.DOCUMENT;
     }
  
     /**
      * set sets the value as a DocumentFragment.
      *
      * @param value The value
      */
     public void set(DocumentFragment value) {
        this.value = value;
        type = Types.DOCUMENTFRAGMENT;
     }
  
     /**
      * set sets the value as an Object.
      *
      * @param value The value
      */
     public void set(Object object) {
        this.value = value;
        type = value != null ? Types.OBJECT
                             : Types.EMPTY;
     }
  
     /**
      * getString returns the value as a String.
      *
      * @return The value
      */
     public String getString() {
        if ( type == Types.STRING )
           return (String)value;
        else
           return value.toString();
     }
  
     /**
      * getBoolean returns the value as a boolean.
      *
      * @return The value
      */
     public boolean getBoolean() {
        if ( type == Types.BOOLEAN )
           return ((Boolean)value).booleanValue();
        else
           return 
"[true][yes][1][y][on]".indexOf("["+value.toString().toLowerCase()+"]") != -1;
     }
  
     /**
      * getByte returns the value as a byte.
      *
      * @return The value
      */
     public byte getByte() {
        if ( type == Types.BYTE )
           return ((Byte)value).byteValue();
        else
           return Byte.parseByte(value.toString());
     }
  
     /**
      * getChar returns the value as a char.
      *
      * @return The value
      */
     public char getChar() {
        if ( type == Types.CHAR )
           return ((Character)value).charValue();
        else
           return value.toString().charAt(0);
     }
  
     /**
      * getShort returns the value as a short.
      *
      * @return The value
      */
     public short getShort() {
        if ( type == Types.SHORT )
           return ((Short)value).shortValue();
        else
           return Short.parseShort(value.toString());
     }
  
     /**
      * getInt returns the value as an int.
      *
      * @return The value
      */
     public int getInt() {
        if ( type == Types.INT )
           return ((Integer)value).intValue();
        else
           return Integer.parseInt(value.toString());
     }
  
     /**
      * getLong returns the value as a long.
      *
      * @return The value
      */
     public long getLong() {
        if ( type == Types.LONG )
           return ((Long)value).longValue();
        else
           return Long.parseLong(value.toString());
     }
  
     /**
      * getFloat returns the value as a float.
      *
      * @return The value
      */
     public float getFloat() {
        if ( type == Types.FLOAT )
           return ((Float)value).floatValue();
        else
           return Float.parseFloat(value.toString());
     }
  
     /**
      * getDouble returns the value as a double.
      *
      * @return The value
      */
     public double getDouble() {
        if ( type == Types.DOUBLE )
           return ((Double)value).doubleValue();
        else
           return Double.parseDouble(value.toString());
     }
  
     /**
      * getElement returns the value as an Element.
      *
      * @return The value
      */
     public Element getElement() {
        if ( type == Types.ELEMENT )
           return (Element)value;
        else
           return null;
     }
  
     /**
      * getDocument returns the value as a Document.
      *
      * @return The value
      */
     public Document getDocument() {
        if ( type == Types.DOCUMENT )
           return (Document)value;
        else
           return null;
     }
  
     /**
      * getDocumentFragment returns the value as a DocumentFragment.
      *
      * @return The value
      */
     public DocumentFragment getDocumentFragment() {
        if ( type == Types.DOCUMENTFRAGMENT )
           return (DocumentFragment)value;
        else
           return null;
     }
  
     /**
      * getObject returns the value as an Object.
      *
      * @return The value
      */
     public Object getObject() {
        return value;
     }
  
     /**
      * toString returns the value as a Stringified representation.
      *
      * @return The stringified value
      */
     public String toString() {
        switch ( type ) {
  
           case Types.ELEMENT:
           case Types.DOCUMENT:
           case Types.DOCUMENTFRAGMENT:
              return TextWriter.toString((Node)value);
  
           default:
              return value.toString();
  
        }
     }
  }
  
  
  
  
  1.2       +5 -47     
xml-xindice/java/src/org/apache/xindice/core/request/URIMapper.java
  
  Index: URIMapper.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/core/request/URIMapper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- URIMapper.java    6 Dec 2001 21:00:14 -0000       1.1
  +++ URIMapper.java    21 Jul 2002 02:52:18 -0000      1.2
  @@ -63,7 +63,6 @@
   import org.apache.xindice.core.*;
   import org.apache.xindice.core.Collection;
   import org.apache.xindice.xml.*;
  -import org.apache.xindice.core.objects.*;
   
   import org.w3c.dom.*;
   
  @@ -84,7 +83,6 @@
      public static final int APPLICATION = 1;
      public static final int COLLECTION = 2;
      public static final int DOCUMENT = 3;
  -   public static final int XMLOBJECT = 4;
   
      private static final String[] EmptyStrings = new String[0];
   
  @@ -99,7 +97,6 @@
      private Database  db = null;
      private Collection   collection = null;
      private Document     document = null;
  -   private XMLObject    xmlObject = null;
      private String       method = null;
      private Container    container = null;
   
  @@ -136,7 +133,7 @@
      }
   
      /* Code for new URL instance of URIMapper */
  -   public Object invokeRequest() throws XMLObjectException {
  +  /* public Object invokeRequest() throws XMLObjectException {
   
         Reflectable obj;
         obj = (Reflectable)getXMLObject();
  @@ -152,7 +149,7 @@
            result = ref.invoke(obj, name, getArguments());
   
         return result;
  -   }
  +   }*/
   
      /**
         Opens a communications link to the resource referenced by this URL,
  @@ -182,20 +179,6 @@
                     output = doc.toString();
                     break;
   
  -               case URIMapper.XMLOBJECT:
  -                  result = invokeRequest();
  -
  -                  if ( result instanceof Node ) {
  -                     Writer ser = new StringWriter();
  -                     TextWriter.write((Node)result, ser);
  -                     output = ser.toString();
  -                  }
  -                  else
  -                     if ( result != null ) {
  -                        output = result.toString();
  -                     }
  -                  break;
  -
                  default:
                     //  Document type not found, output error message
                     throw new Exception("Content type unsupported");
  @@ -279,8 +262,6 @@
      }
   
      public void reclaim() {
  -      if ( xmlObject != null && xmlObject instanceof Poolable )
  -         ((Poolable)xmlObject).reclaim();
         reset();
         if ( pool != null )
            pool.putObject(this);
  @@ -296,7 +277,6 @@
         db = null;
         collection = null;
         document = null;
  -      xmlObject = null;
         params = null;
         args = null;
         container = null;
  @@ -446,7 +426,7 @@
            params = new Properties();
      }
   
  -   private void parseXMLObject() {
  +  /* private void parseXMLObject() {
         try {
            if ( lastChar == '/' )
               method = parseName("/(?");
  @@ -459,7 +439,7 @@
         catch ( Exception e ) {
            org.apache.xindice.Debug.printStackTrace(e);
         }
  -   }
  +   }*/
   
      /**
       * parse parses the URI.
  @@ -523,14 +503,6 @@
               document = container.getDocument();
               return DOCUMENT;
   
  -         case XMLOBJECT:
  -            xmlObject = col.getXMLObject(name);
  -            if ( xmlObject != null ) {
  -               parseXMLObject();
  -               return XMLOBJECT;
  -            }
  -            break;
  -
            case COLLECTION:
               Collection c = col.getCollection(name);
               if ( c != null ) {
  @@ -558,9 +530,6 @@
         if (col.getCollection(name) != null) {
            return COLLECTION;
         }
  -      else if (col.getXMLObject(name) != null) {
  -         return XMLOBJECT;
  -      }
         else if ((col.getFiler() != null) && (col.getContainer(name) != null)) 
{
            return DOCUMENT;
         }
  @@ -622,17 +591,6 @@
       */
      public Container getContainer() {
         return container;
  -   }
  -
  -   /**
  -    * getXMLObject returns the XMLObject that was resolved in the parsing
  -    * of the URI.  If no XMLObject was resolve, this method will return
  -    * null.
  -    *
  -    * @return The XMLObject
  -    */
  -   public XMLObject getXMLObject() {
  -      return xmlObject;
      }
   
      /**
  
  
  
  1.4       +3 -3      
xml-xindice/java/src/org/apache/xindice/server/Xindice.java
  
  Index: Xindice.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/server/Xindice.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Xindice.java      14 Mar 2002 06:15:16 -0000      1.3
  +++ Xindice.java      21 Jul 2002 02:52:18 -0000      1.4
  @@ -88,7 +88,7 @@
      public static final String Company = "The Apache Foundation";
      public static final String URL = "http://xml.apache.org/xindice/";;
   
  -   public static void main(String[] args) {
  +   /*public static void main(String[] args) {
         System.out.println();
         System.out.println(Title+" "+Version+" ("+Codename+")");
         System.out.println();
  @@ -98,5 +98,5 @@
            File cfg = new File(new 
File(System.getProperty(PROP_XINDICE_HOME)), "/config/system.xml");
            new Kernel(cfg.getAbsolutePath());
         }
  -   }
  +   }*/
   }
  
  
  
  1.1                  
xml-xindice/java/src/org/apache/xindice/server/XindiceServlet.java
  
  Index: XindiceServlet.java
  ===================================================================
  package org.apache.xindice.server;
  
  /*
   * The Apache Software License, Version 1.1
   *
   *
   * Copyright (c) 2001 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *    notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *    notice, this list of conditions and the following disclaimer in
   *    the documentation and/or other materials provided with the
   *    distribution.
   *
   * 3. The end-user documentation included with the redistribution,
   *    if any, must include the following acknowledgment:
   *       "This product includes software developed by the
   *        Apache Software Foundation (http://www.apache.org/)."
   *    Alternately, this acknowledgment may appear in the software itself,
   *    if and wherever such third-party acknowledgments normally appear.
   *
   * 4. The names "XML-RPC" and "Apache Software Foundation" must
   *    not be used to endorse or promote products derived from this
   *    software without prior written permission. For written
   *    permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called "Apache",
   *    nor may "Apache" appear in their name, without prior written
   *    permission of the Apache Software Foundation.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * ====================================================================
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation.  For more
   * information on the Apache Software Foundation, please see
   * <http://www.apache.org/>.
   */
  
  import javax.servlet.*;
  import javax.servlet.http.*;
  import java.io.*;
  import java.util.Vector;
  
  import org.w3c.dom.*;
  
  import org.apache.xmlrpc.*;
  import org.apache.xindice.server.rpc.*;
  import org.apache.xindice.core.*;
  import org.apache.xindice.xml.dom.*;
  import org.apache.xindice.util.*;
  
  
  /**
   * A <code>HttpServlet</code> that enables XML-RPC access to a
   * Xindice database instance.
   *
   * @author <a href="mailto:[EMAIL PROTECTED]">Kimbro Staken</a>
   */
  public class XindiceServlet extends HttpServlet
  {
      private XmlRpcServer xmlrpc;
      private Database db;
  
      public void init (ServletConfig config) throws ServletException
      {
        // String url = config.getInitParameter ("url");
  
         db = new Database();
         // TODO: this needs to be configurable.
         String configXML = "<root-collection dbroot=\"./db/\" name=\"db\">" +
            "<queryengine>" +
            "<resolver autoindex=\"false\" 
class=\"org.apache.xindice.core.query.XPathQueryResolver\" />" +
            "<resolver 
class=\"org.apache.xindice.core.xupdate.XUpdateQueryResolver\" />" +
            "</queryengine>" +
            "</root-collection>";
  
         try {
            Document doc = DOMParser.toDocument(configXML);
  
            db.setConfig(new Configuration(doc.getDocumentElement(), false));
         }
         catch (Exception e) {
            e.printStackTrace();
         }
  
         xmlrpc = new XmlRpcServer ();
         try {
            xmlrpc.addHandler ("$default", new RPCMessageInterface());
         }
         catch (Exception x) {
            throw new ServletException ("Startup error");
         }
      }
  
      // TODO: add get handling to provide simple HTTP access to the Xindice 
instance.
  
      // For post we're just handling XML-RPC
      public void doPost(HttpServletRequest req,
              HttpServletResponse res) throws ServletException, IOException
      {
          byte[] result = xmlrpc.execute (req.getInputStream ());
          res.setContentType("text/xml");
          res.setContentLength (result.length);
          OutputStream output = res.getOutputStream();
          output.write (result);
          output.flush ();
      }
  
      public void destroy() {
         try {
            // When the servlet engine goes down we need to close the
            // database instance.
            if (db != null) {
               db.close();
            }          
         }
         catch (Exception e) {
            
         }
      }
  }
  
  
  
  1.3       +3 -3      
xml-xindice/java/src/org/apache/xindice/server/rpc/messages/Shutdown.java
  
  Index: Shutdown.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/server/rpc/messages/Shutdown.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Shutdown.java     19 Jul 2002 03:28:37 -0000      1.2
  +++ Shutdown.java     21 Jul 2002 02:52:18 -0000      1.3
  @@ -65,12 +65,12 @@
   import org.apache.xindice.server.rpc.*;
   
   /**
  - *
  + * This message probably isn't necessary anymore.
    */
   public class Shutdown extends RPCDefaultMessage {   
      
      public Hashtable execute(Hashtable message) throws Exception {      
  -      Kernel.getKernel().shutDown(1);
  +      //Kernel.getKernel().shutDown(1);
   
         Hashtable result = new Hashtable();
         result.put(RESULT, "yes");
  
  
  
  1.3       +4 -4      
xml-xindice/java/src/org/apache/xindice/xml/dom/ElementImpl.java
  
  Index: ElementImpl.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xindice/java/src/org/apache/xindice/xml/dom/ElementImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ElementImpl.java  6 Jan 2002 18:10:17 -0000       1.2
  +++ ElementImpl.java  21 Jul 2002 02:52:18 -0000      1.3
  @@ -63,7 +63,7 @@
   import org.apache.xindice.core.data.*;
   import org.apache.xindice.xml.*;
   import org.apache.xindice.core.request.*;
  -import org.apache.xindice.core.objects.*;
  +//import org.apache.xindice.core.objects.*;
   import org.apache.xindice.util.*;
   
   import org.w3c.dom.*;
  @@ -225,7 +225,7 @@
                     obj = 
doc.importNode(map.getDocument().getDocumentElement(), true);
                     break;
   
  -               case URIMapper.XMLOBJECT:
  +               /*case URIMapper.XMLOBJECT:
                     // Resolve The Object/Reflector
                     Reflectable target = map.getXMLObject();
                     String name = map.getMethod();
  @@ -257,7 +257,7 @@
                        else
                           obj = doc.createTextNode(new 
Variant(result).toString());
                     }
  -                  break;
  +                  break;*/
   
               }
               map.reclaim();
  
  
  
  1.3       +2 -2      xml-xindice/java/tests/stress/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/xml-xindice/java/tests/stress/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- build.xml 12 Jul 2002 02:46:11 -0000      1.2
  +++ build.xml 21 Jul 2002 02:52:18 -0000      1.3
  @@ -85,7 +85,7 @@
     <target name="run">
       <java classpathref="project.class.path" classname="Stress" fork="true">
         <arg value="10"/>
  -      <arg value="10"/>
  +      <arg value="100"/>
       </java>
     </target>
     
  
  
  
  1.3       +2 -2      xml-xindice/java/tests/stress/src/AddManyDocuments.java
  
  Index: AddManyDocuments.java
  ===================================================================
  RCS file: /home/cvs/xml-xindice/java/tests/stress/src/AddManyDocuments.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- AddManyDocuments.java     12 Jul 2002 02:46:11 -0000      1.2
  +++ AddManyDocuments.java     21 Jul 2002 02:52:18 -0000      1.3
  @@ -82,7 +82,7 @@
            Database database = (Database) c.newInstance();
            DatabaseManager.registerDatabase(database);
            col =
  -            DatabaseManager.getCollection("xmldb:xindice:///db/addressbook");
  +            
DatabaseManager.getCollection("xmldb:xindice://127.0.0.1:8080/db/addressbook");
                              
            System.out.println("Adding " + count + " documents");
            
  
  
  
  1.3       +2 -2      xml-xindice/java/tests/stress/src/ThrashCollection.java
  
  Index: ThrashCollection.java
  ===================================================================
  RCS file: /home/cvs/xml-xindice/java/tests/stress/src/ThrashCollection.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ThrashCollection.java     12 Jul 2002 02:46:11 -0000      1.2
  +++ ThrashCollection.java     21 Jul 2002 02:52:18 -0000      1.3
  @@ -82,7 +82,7 @@
            Database database = (Database) c.newInstance();
            DatabaseManager.registerDatabase(database);
            col =
  -            DatabaseManager.getCollection("xmldb:xindice:///db/addressbook");
  +            
DatabaseManager.getCollection("xmldb:xindice://127.0.0.1:8080/db/addressbook");
                              
            System.out.println("Adding " + count + " documents");
            
  
  
  

Reply via email to