geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r420719 [1/2] - in /geronimo/xbean/branches/colossus: ./ maven-xbean-plugin/ xbean-bootstrap/ xbean-bootstrap/src/ xbean-bootstrap/src/main/ xbean-bootstrap/src/main/java/ xbean-bootstrap/src/main/java/org/ xbean-bootstrap/src/main/java/org...
Date Tue, 11 Jul 2006 04:39:41 GMT
Author: dain
Date: Mon Jul 10 21:39:36 2006
New Revision: 420719

URL: http://svn.apache.org/viewvc?rev=420719&view=rev
Log:
Changed version to 2.5-colossus to avoid any conflicts in the local repository.
Added bootstrap module to easily launch a vm without requiring an initial class path setting on the command line or via a manifest class path entry.
Added colossus module which will contain the colossus server binary.

Added:
    geronimo/xbean/branches/colossus/xbean-bootstrap/   (with props)
    geronimo/xbean/branches/colossus/xbean-bootstrap/LICENSE.txt
    geronimo/xbean/branches/colossus/xbean-bootstrap/NOTICE.txt
    geronimo/xbean/branches/colossus/xbean-bootstrap/pom.xml
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/Bootstrap.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapFinder.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapLoader.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/ClassLoaderFactory.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/FatalStartupError.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/UrlClassLoaderFactory.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/LICENSE
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/NOTICE
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/org/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/org/apache/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/org/apache/xbean/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/org/apache/xbean/bootstrap/
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/java/org/apache/xbean/bootstrap/BootstrapTest.java
    geronimo/xbean/branches/colossus/xbean-bootstrap/src/test/resources/
    geronimo/xbean/branches/colossus/xbean-colossus/   (with props)
    geronimo/xbean/branches/colossus/xbean-colossus/LICENSE.txt
    geronimo/xbean/branches/colossus/xbean-colossus/NOTICE.txt
    geronimo/xbean/branches/colossus/xbean-colossus/pom.xml
    geronimo/xbean/branches/colossus/xbean-colossus/src/
    geronimo/xbean/branches/colossus/xbean-colossus/src/assemble/
    geronimo/xbean/branches/colossus/xbean-colossus/src/assemble/colossus.xml
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/bin/
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/bin/bootstrap.properties
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/bin/xbean-debug.sh
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/bin/xbean.sh   (with props)
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/conf/
    geronimo/xbean/branches/colossus/xbean-colossus/src/main/config/conf/server.xml
    geronimo/xbean/branches/colossus/xbean-server/src/main/java/org/apache/xbean/server/main/DaemonMain.java
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/org/
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/org/apache/
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/org/apache/xbean/
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/org/apache/xbean/bootstrap/
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/org/apache/xbean/bootstrap/BootstrapLoader
Modified:
    geronimo/xbean/branches/colossus/maven-xbean-plugin/   (props changed)
    geronimo/xbean/branches/colossus/maven-xbean-plugin/pom.xml
    geronimo/xbean/branches/colossus/pom.xml
    geronimo/xbean/branches/colossus/xbean-classpath/pom.xml
    geronimo/xbean/branches/colossus/xbean-finder/pom.xml
    geronimo/xbean/branches/colossus/xbean-jaxb/pom.xml
    geronimo/xbean/branches/colossus/xbean-jmx/pom.xml
    geronimo/xbean/branches/colossus/xbean-kernel/pom.xml
    geronimo/xbean/branches/colossus/xbean-osgi/pom.xml
    geronimo/xbean/branches/colossus/xbean-oxm/pom.xml
    geronimo/xbean/branches/colossus/xbean-reflect/pom.xml
    geronimo/xbean/branches/colossus/xbean-sca/pom.xml
    geronimo/xbean/branches/colossus/xbean-server/pom.xml
    geronimo/xbean/branches/colossus/xbean-server/src/main/java/org/apache/xbean/server/spring/main/SpringBootstrap.java
    geronimo/xbean/branches/colossus/xbean-server/src/main/resources/META-INF/xbean-bootstrap.xml
    geronimo/xbean/branches/colossus/xbean-server/src/test/java/org/apache/xbean/server/deployer/DeployerTest.java
    geronimo/xbean/branches/colossus/xbean-server/src/test/java/org/apache/xbean/server/spring/main/SpringBootstrapTest.java
    geronimo/xbean/branches/colossus/xbean-server/src/test/resources/test-xbean-bootstrap.xml
    geronimo/xbean/branches/colossus/xbean-spring/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-common/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.4/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.4/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.5/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.5/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.6/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.6/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.7/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.7/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.8/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/1.2.8/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/2.0-m5/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/2.0-m5/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/2.0-rc1/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/2.0-rc1/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/core/   (props changed)
    geronimo/xbean/branches/colossus/xbean-spring-itests/core/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-itests/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-v1/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring-v2/pom.xml
    geronimo/xbean/branches/colossus/xbean-spring/pom.xml
    geronimo/xbean/branches/colossus/xbean-telnet/pom.xml
    geronimo/xbean/branches/colossus/xbean-tiger/pom.xml

Propchange: geronimo/xbean/branches/colossus/maven-xbean-plugin/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Mon Jul 10 21:39:36 2006
@@ -1,3 +1,10 @@
-target
-.classpath
+
+*.iml
+*.ipr
+*.iws
 .project
+.classpath
+maven.log
+junit*.properties
+target
+.wtpmodules

Modified: geronimo/xbean/branches/colossus/maven-xbean-plugin/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/maven-xbean-plugin/pom.xml?rev=420719&r1=420718&r2=420719&view=diff
==============================================================================
--- geronimo/xbean/branches/colossus/maven-xbean-plugin/pom.xml (original)
+++ geronimo/xbean/branches/colossus/maven-xbean-plugin/pom.xml Mon Jul 10 21:39:36 2006
@@ -2,13 +2,13 @@
   <parent>
     <artifactId>xbean</artifactId>
     <groupId>org.apache.xbean</groupId>
-    <version>2.5-SNAPSHOT</version>
+    <version>2.5-colossus</version>
   </parent>
   <modelVersion>4.0.0</modelVersion>
   <artifactId>maven-xbean-plugin</artifactId>
   <packaging>maven-plugin</packaging>
   <name>Maven XBean Plugin</name>
-  <version>2.5-SNAPSHOT</version>
+  <version>2.5-colossus</version>
   <dependencies>
     <dependency>
       <groupId>org.apache.maven</groupId>

Modified: geronimo/xbean/branches/colossus/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/pom.xml?rev=420719&r1=420718&r2=420719&view=diff
==============================================================================
--- geronimo/xbean/branches/colossus/pom.xml (original)
+++ geronimo/xbean/branches/colossus/pom.xml Mon Jul 10 21:39:36 2006
@@ -11,7 +11,7 @@
   <packaging>pom</packaging>
 
   <name>XBean</name>
-  <version>2.5-SNAPSHOT</version>
+  <version>2.5-colossus</version>
   <description>XBean is a plugin based server architecture.</description>
   <url>http://xbean.org</url>
 
@@ -34,7 +34,7 @@
   <properties>
     <m1.repo>scp://minotaur.apache.org/www/people.apache.org/repository</m1.repo>
     <m2.repo>scp://minotaur.apache.org/www/people.apache.org/maven-snapshot-repository</m2.repo>
-    <site.repo>scp://minotaur.apache.org/www/geronimo.apache.org/xbean/dist/xbean-2.5-SNAPSHOT/site</site.repo>
+    <site.repo>scp://minotaur.apache.org/www/geronimo.apache.org/xbean/dist/xbean-2.5-colossus/site</site.repo>
   </properties>
 
   <mailingLists>
@@ -154,18 +154,38 @@
           </execution>
         </executions>
       </plugin>
+      <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <configuration>
+          <source>1.5</source>
+          <target>1.5</target>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <forkMode>once</forkMode>
+          <argLine>-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005</argLine>
+        </configuration>
+      </plugin>
     </plugins>
   </build>
 
   <modules>
+    <module>xbean-bootstrap</module>
     <module>xbean-classpath</module>
     <!--
     <module>xbean-jmx</module>
     -->
+    <module>xbean-colossus</module>
     <module>xbean-kernel</module>
     <module>xbean-osgi</module>
     <module>xbean-reflect</module>
     <module>xbean-server</module>
+    <!--
+    <module>xbean-spring-bootstrap</module>
+    -->    
     <module>xbean-spring-common</module>
     <module>xbean-spring-v1</module>
     <module>xbean-spring-v2</module>
@@ -184,7 +204,7 @@
         <modules>
           <module>xbean-tiger</module>
           <module>xbean-finder</module>
-          <module>xbean-jaxb</module>
+          <!--module>xbean-jaxb</module-->
         </modules>
       </profile>
   </profiles>
@@ -279,33 +299,53 @@
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
+        <artifactId>xbean-bootstrap</artifactId>
+        <version>2.5-colossus</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.xbean</groupId>
+        <artifactId>xbean-colossus</artifactId>
+        <version>2.5-colossus</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-kernel</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.xbean</groupId>
+        <artifactId>xbean-server</artifactId>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-spring</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.xbean</groupId>
+        <artifactId>xbean-spring-bootstrap</artifactId>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-spring-common</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-spring-v1</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-spring-v2</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>org.apache.xbean</groupId>
         <artifactId>xbean-spring</artifactId>
-        <version>2.5-SNAPSHOT</version>
+        <version>2.5-colossus</version>
       </dependency>
       <dependency>
         <groupId>qdox</groupId>

Propchange: geronimo/xbean/branches/colossus/xbean-bootstrap/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Mon Jul 10 21:39:36 2006
@@ -0,0 +1,10 @@
+
+*.iml
+*.ipr
+*.iws
+.project
+.classpath
+maven.log
+junit*.properties
+target
+.wtpmodules

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/LICENSE.txt
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/LICENSE.txt?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/LICENSE.txt (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/LICENSE.txt Mon Jul 10 21:39:36 2006
@@ -0,0 +1,203 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/NOTICE.txt
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/NOTICE.txt?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/NOTICE.txt (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/NOTICE.txt Mon Jul 10 21:39:36 2006
@@ -0,0 +1,3 @@
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).
+

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/pom.xml?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/pom.xml (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/pom.xml Mon Jul 10 21:39:36 2006
@@ -0,0 +1,29 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <parent>
+    <artifactId>xbean</artifactId>
+    <groupId>org.apache.xbean</groupId>
+    <version>2.5-colossus</version>
+  </parent>
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>xbean-bootstrap</artifactId>
+  <name>XBean :: Bootstrap</name>
+  <version>2.5-colossus</version>
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jar-plugin</artifactId>
+        <configuration>
+          <archive>
+            <index>true</index>
+            <manifest>
+              <mainClass>org.apache.xbean.bootstrap.Bootstrap</mainClass>
+              <packageName>org.apache.xbean.bootstrap</packageName>
+            </manifest>
+          </archive>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+</project>

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/Bootstrap.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/Bootstrap.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/Bootstrap.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/Bootstrap.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,518 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+import java.io.BufferedInputStream;
+import java.io.Closeable;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.JarURLConnection;
+import java.net.URI;
+import java.net.URL;
+import java.net.URLConnection;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Properties;
+import java.util.StringTokenizer;
+import java.util.Set;
+import java.util.LinkedHashSet;
+
+/**
+ * SpringBootstrap is the main class used by a Spring based server.  This class uses the following strategies to determine
+ * the configuration file to load:
+ * <p/>
+ * Command line parameter --bootstrap FILE
+ * Manifest entry XBean-Bootstrap in the startup jar
+ * META-INF/xbean-bootstrap.xml
+ * <p/>
+ * This class atempts to first load the configuration file from the local file system and if that fails it attempts to
+ * load it from the classpath.
+ * <p/>
+ * SpringBootstrap expects the configuration to contain a service with the id "main" which is an implementation of
+ * org.apache.xbean.server.main.Main.
+ * <p/>
+ * This class will set the system property xbean.base.dir to the directory containing the startup jar if the property
+ * has not alredy been set (on the command line).
+ *
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+public class Bootstrap {
+    public static final String BOOTSTRAP_DIR = "xbean.bootstrap.dir";
+
+    public static final String HOME_DIR = "xbean.home.dir";
+    private static final String HOME_DIR_DEFAULT = "..";
+
+    public static final String CLASS_PATH = "xbean.bootstrap.ClassPath";
+    private static final String CLASS_PATH_DEFAULT = "lib/*.jar,lib/*.zip";
+
+    public static final String CLASS_LOADER_FACTORY = "xbean.bootstrap.ClassLoaderFactory";
+
+    public static final String LOADER = "xbean.bootstrap.BootstrapLoader";
+    private static final String LOADER_MANIFEST_SERVICE = "META-INF/org/apache/xbean/bootstrap/BootstrapLoader";
+
+    private List<String> arguments;
+    private Properties properties;
+
+    private String bootstrapDirectory;
+    private String homeDirectory;
+    private List<String> classPath;
+    private ClassLoaderFactory classLoaderFactory;
+    private String bootstrapLoader;
+
+    /**
+     * Initializes and boots using the supplied arguments.  If an error is thrown from the boot method,
+     * this method will print the error to standard error along with the stack trace and exit with the exit specified
+     * in the FatalStartupError or exit code 9 if the error was not a FatalStartupError.
+     *
+     * @param args the arguments used to start the server
+     */
+    public static void main(String[] args) {
+        Bootstrap bootstrap = new Bootstrap();
+        Bootstrap.main(new LinkedList<String>(Arrays.asList(args)), bootstrap);
+    }
+
+    /**
+     * Like the main(args) method but allows a configured bootstrap instance to be passed in.
+     *
+     * @see #main(String[])
+     */
+    public static void main(List<String> args, Bootstrap bootstrap) {
+        bootstrap.initialize(args);
+
+        try {
+            bootstrap.boot();
+        } catch (FatalStartupError e) {
+            System.err.println(e.getMessage());
+            if (e.getCause() != null) {
+                e.getCause().printStackTrace();
+            }
+            System.exit(e.getExitCode());
+        } catch (Throwable e) {
+            System.err.println("Unknown error");
+            e.printStackTrace();
+            System.exit(9);
+        }
+    }
+
+    /**
+     * Gets the arguments passed to the bootstrap loader.
+     *
+     * @return the arguments passed to the bootstrap loader
+     */
+    public List<String> getArguments() {
+        return Collections.unmodifiableList(arguments);
+    }
+
+    /**
+     * Sets the arguments passed to the bootstrap loader.
+     *
+     * @param arguments the arguments passed to the bootstrap loader
+     */
+    public void setArguments(List<String> arguments) {
+        if (arguments != null) {
+            this.arguments = new LinkedList<String>(arguments);
+        } else {
+            this.arguments = null;
+        }
+    }
+
+    /**
+     * Gets the properties passed to the bootstrap loader.
+     *
+     * @return the properties passed to the bootstrap loader
+     */
+    public Properties getProperties() {
+        return properties;
+    }
+
+    /**
+     * Sets the properties passed to the bootstrap loader.
+     *
+     * @param properties the properties passed to the bootstrap loader
+     */
+    public void setProperties(Properties properties) {
+        this.properties = properties;
+    }
+
+    /**
+     * Gets the bootstrap directory.
+     *
+     * @return the base directory
+     */
+    public String getBootstrapDirectory() {
+        return bootstrapDirectory;
+    }
+
+    /**
+     * Sets the bootstrap directory.
+     *
+     * @param bootstrapDirectory the bootstrap directory
+     */
+    public void setBootstrapDirectory(String bootstrapDirectory) {
+        this.bootstrapDirectory = bootstrapDirectory;
+    }
+
+    /**
+     * Gets the home directory relative to the bootstrap directory.
+     * @return the home directory relative to the bootstrap directory
+     */
+    public String getHomeDirectory() {
+        return homeDirectory;
+    }
+
+    /**
+     * Sets the home directory relative to the bootstrap directory.
+     * @param homeDirectory the home directory relative to the bootstrap directory
+     */
+    public void setHomeDirectory(String homeDirectory) {
+        this.homeDirectory = homeDirectory;
+    }
+
+    /**
+     * Gets the class path used to create the bootstrap class loader.
+     *
+     * @return class path used to create the bootstrap class loader
+     */
+    public List<String> getClassPath() {
+        return classPath;
+    }
+
+    /**
+     * Sets the class path used to create the bootstrap class loader.
+     *
+     * @param classPath the class path used to create the bootstrap class loader
+     */
+    public void setClassPath(List<String> classPath) {
+        this.classPath = classPath;
+    }
+
+    /**
+     * Gets the factory used to create the bootstrap class loader.
+     *
+     * @return factory used to create the bootstrap class loader
+     */
+    public ClassLoaderFactory getClassLoaderFactory() {
+        return classLoaderFactory;
+    }
+
+    /**
+     * Sets the factory used to create the bootstrap class loader.
+     *
+     * @param classLoaderFactory the factory used to create the bootstrap class loader
+     */
+    public void setClassLoaderFactory(ClassLoaderFactory classLoaderFactory) {
+        this.classLoaderFactory = classLoaderFactory;
+    }
+
+    /**
+     * Gets the name of the loader class to use for bootstraping.
+     *
+     * @return the name of the loader class to use for bootstraping
+     */
+    public String getBootstrapLoader() {
+        return bootstrapLoader;
+    }
+
+    /**
+     * Sets the name of the loader class to use for bootstraping.
+     *
+     * @param bootstrapLoader the name of the loader class to use for bootstraping
+     */
+    public void setBootstrapLoader(String bootstrapLoader) {
+        this.bootstrapLoader = bootstrapLoader;
+    }
+
+    /**
+     * Initializes the bootstrap directory, properties, class path, class loader factory, and bootstrap loader.
+     *
+     * @param args the arguments passed to main
+     */
+    public void initialize(List<String> args) {
+        arguments = new LinkedList<String>(args);
+        extractProperties(arguments, System.getProperties());
+
+        // Determine the xbean bootstrap directory
+        // this must be done before the properties are initialized because the initialization
+        // code loads a properties file from the bootstrap directory
+        if (bootstrapDirectory == null) {
+            bootstrapDirectory = System.getProperty(BOOTSTRAP_DIR);
+        }
+
+        // Determine the startup dir
+        if (bootstrapDirectory == null) {
+            URL bootstrapClassUrl = getClass().getClassLoader().getResource(Bootstrap.class.getName().replace('.', '/') + ".class");
+            if (bootstrapClassUrl == null) {
+                throw new FatalStartupError("Could not determine XBean installation directory", 9);
+            }
+
+            try {
+                URLConnection urlConnection = bootstrapClassUrl.openConnection();
+
+                if (urlConnection instanceof JarURLConnection) {
+                    JarURLConnection jarConnection = (JarURLConnection) urlConnection;
+                    bootstrapClassUrl = jarConnection.getJarFileURL();
+
+                    bootstrapDirectory = new File(new URI(bootstrapClassUrl.toString())).getParentFile().getAbsolutePath();
+                } else {
+                    File startupDir = new File(new URI(bootstrapClassUrl.toString())).getParentFile();
+                    for (char c : getClass().getName().toCharArray()) {
+                        if (c == '.') {
+                            startupDir = startupDir.getParentFile();
+                        }
+                    }
+                    bootstrapDirectory = startupDir.getAbsolutePath();
+                }
+            } catch (Exception e) {
+                throw new FatalStartupError("Could not determine XBean installation directory", 9, e);
+            }
+        }
+
+        // properties
+        initalizeProperties();
+
+        // home directory
+        initializeHomeDirectory();
+
+        // class path
+        initializeClassPath();
+
+        // class loader factory
+        initializeClassLoaderFactory();
+
+        // bootstrap loader
+        initalizeBootstrapLoader();
+    }
+
+    private void initalizeProperties() {
+        properties = new Properties();
+
+        // load the meta-inf properties
+        loadProperties(getClass().getClassLoader().getResourceAsStream("META-INF/xbean-bootstrap.properties"));
+
+        // load the bin/bootstrap.properties file
+        try {
+            loadProperties(new FileInputStream(new File(bootstrapDirectory, "bootstrap.properties")));
+        } catch (FileNotFoundException ignored) {
+        }
+
+        // Add system properties
+        properties.putAll(System.getProperties());
+    }
+
+    private void initializeHomeDirectory() {
+        if (homeDirectory == null) {
+            homeDirectory = properties.getProperty(HOME_DIR, HOME_DIR_DEFAULT);
+        }
+    }
+
+    private void loadProperties(InputStream in) {
+        if (in != null) {
+            try {
+                properties.load(in);
+            } catch (IOException e) {
+            } finally {
+                close(in);
+                in = null;
+            }
+        }
+    }
+
+    private void initializeClassPath() {
+        String cp = properties.getProperty(CLASS_PATH, CLASS_PATH_DEFAULT);
+
+        classPath = new ArrayList<String>();
+        StringTokenizer tokenizer = new StringTokenizer(cp, ",");
+        while (tokenizer.hasMoreElements()) {
+            String element = tokenizer.nextToken();
+
+            // strip of quotes
+            if (element.length() > 2 && element.startsWith("\"") && element.endsWith("\"")) {
+                element = element.substring(1, element.length() - 1);
+            }
+
+            classPath.add(element);
+        }
+    }
+
+    private void initializeClassLoaderFactory() {
+        String factoryName = properties.getProperty(CLASS_LOADER_FACTORY);
+
+        if (factoryName == null) {
+            return;
+        }
+
+        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
+        if (classLoader == null) {
+            classLoader = getClass().getClassLoader();
+        }
+
+        try {
+            Class<?> factoryClass = classLoader.loadClass(factoryName);
+            classLoaderFactory = (ClassLoaderFactory) factoryClass.newInstance();
+        } catch (Exception e) {
+            throw new FatalStartupError("Unable to instantiate the class loader factory " + factoryName, e);
+        }
+    }
+
+    private void initalizeBootstrapLoader() {
+        bootstrapLoader = properties.getProperty(LOADER, bootstrapLoader);
+    }
+
+    /**
+     * Loads the main instance from the Spring configuration file and executes it.
+     */
+    public void boot() {
+        // verify the xbean bootstrap directory
+        if (bootstrapDirectory == null) {
+            throw new FatalStartupError("Bootstrap directory was not set");
+
+        }
+        if (!new File(bootstrapDirectory).isDirectory()) {
+            throw new FatalStartupError("Bootstrap directory is not a directory: " + bootstrapDirectory);
+
+        }
+
+        File homeDirectory = new File(bootstrapDirectory, this.homeDirectory);
+        if (!homeDirectory.isDirectory()) {
+            throw new IllegalArgumentException("XBean home directory is not a directory: " + homeDirectory.getAbsolutePath());
+        }
+
+        // verify main arguments
+        if (arguments == null) {
+            arguments = Collections.emptyList();
+        }
+
+        // create the class loader
+        ClassLoader classLoader = createClassLoader();
+
+        // set the thread context class loader
+        ClassLoader oldClassLoader = Thread.currentThread().getContextClassLoader();
+        Thread.currentThread().setContextClassLoader(classLoader);
+        try {
+            // set directory properties
+            System.setProperty(BOOTSTRAP_DIR, bootstrapDirectory);
+            System.setProperty(HOME_DIR, homeDirectory.getAbsolutePath());
+
+            properties.setProperty(BOOTSTRAP_DIR, bootstrapDirectory);
+            properties.setProperty(HOME_DIR, homeDirectory.getAbsolutePath());
+
+            // load the bootstrap class
+            BootstrapLoader bootstrapLoader = loadBootstrap(classLoader);
+
+            // boot
+            bootstrapLoader.boot(arguments.toArray(new String[arguments.size()]), properties, classLoader);
+        } finally {
+            Thread.currentThread().setContextClassLoader(oldClassLoader);
+        }
+
+    }
+
+    private ClassLoader createClassLoader() {
+        if (classPath == null) {
+            return getClass().getClassLoader();
+        }
+
+        File homeDirectory = new File(bootstrapDirectory, this.homeDirectory);
+        Set<URL> urls = new LinkedHashSet<URL>();
+        for (String entry : classPath) {
+            urls.addAll(BootstrapFinder.search(homeDirectory, entry));
+        }
+
+        ClassLoaderFactory factory = classLoaderFactory;
+        if (factory == null) {
+            factory = new UrlClassLoaderFactory();
+        }
+        ClassLoader classLoader = factory.createClassLoader(getClass().getClassLoader(), new ArrayList<URL>(urls));
+        return classLoader;
+    }
+
+    private BootstrapLoader loadBootstrap(ClassLoader classLoader) {
+        if (bootstrapLoader == null) {
+            // attempt to find the loader via manifest services
+            bootstrapLoader = findBootstrapLoader(classLoader);
+        }
+        try {
+            Class<?> factoryClass = classLoader.loadClass(bootstrapLoader);
+            BootstrapLoader bootstrapLoader = (BootstrapLoader) factoryClass.newInstance();
+            return bootstrapLoader;
+        } catch (Exception e) {
+            throw new FatalStartupError("Unable to instantiate the bootstrap loader " + bootstrapLoader, e);
+        }
+    }
+
+    public static String findBootstrapLoader(ClassLoader classLoader) {
+        URL resource = classLoader.getResource(LOADER_MANIFEST_SERVICE);
+        if (resource == null) {
+            throw new FatalStartupError("Could not find a bootstrap loader in " + LOADER_MANIFEST_SERVICE);
+        }
+
+        InputStream in = null;
+        BufferedInputStream reader = null;
+        try {
+            in = resource.openStream();
+            StringBuffer sb = new StringBuffer();
+
+            reader = new BufferedInputStream(in);
+
+            int b = reader.read();
+            while (b != -1) {
+                sb.append((char) b);
+                b = reader.read();
+            }
+
+            return sb.toString().trim();
+        } catch (IOException ignored) {
+            throw new FatalStartupError("Unable to read bootstrap loader name from " + resource);
+        } finally {
+            close(in);
+            close(reader);
+        }
+    }
+
+    private static void extractProperties(List<String> arguments, Properties properties) {
+        for (Iterator<String> iterator = arguments.iterator(); iterator.hasNext();) {
+            String arg = iterator.next();
+            if (arg.startsWith("-D")) {
+                int equalsIndex = arg.indexOf("=");
+                String name = arg.substring(2, equalsIndex);
+                String value = arg.substring(equalsIndex + 1);
+
+                properties.setProperty(name, value);
+
+                iterator.remove();
+            }
+        }
+    }
+
+    private static void close(Closeable c) {
+        if (c != null) {
+            try {
+                c.close();
+            } catch (IOException e) {
+            }
+        }
+    }
+}
\ No newline at end of file

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapFinder.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapFinder.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapFinder.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapFinder.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,602 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.Collections;
+import java.util.Enumeration;
+import java.util.LinkedHashMap;
+import java.util.LinkedHashSet;
+import java.util.Locale;
+import java.util.Map;
+import java.util.Set;
+import java.util.jar.JarFile;
+import java.util.zip.ZipEntry;
+
+/**
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+class BootstrapFinder {
+    private final static boolean onNetWare;
+    private final static boolean onDos;
+
+    static {
+        onNetWare = System.getProperty("os.name").toLowerCase(Locale.US).indexOf("netware") > -1;
+        if (!onNetWare) {
+            onDos = System.getProperty("path.separator").equals(";");
+        } else {
+            onDos = false;
+        }
+    }
+
+    private BootstrapFinder() {
+    }
+
+    public static Set<URL> search(File root, String pattern) {
+        if (root.isDirectory()) {
+            if (!hasWildcards(pattern)) {
+                File match = new File(root, pattern);
+                if (match.exists() && match.canRead()) {
+                    try {
+                        return Collections.singleton(match.toURL());
+                    } catch (MalformedURLException ignored) {
+                    }
+                }
+                return Collections.emptySet();
+            } else {
+                Set<URL> matches = new LinkedHashSet<URL>();
+                Map<String, File> files = listAllFileNames(root);
+                for (Map.Entry<String, File> entry : files.entrySet()) {
+                    String fileName = entry.getKey();
+                    if (matchPath(pattern, fileName)) {
+                        File file = entry.getValue();
+                        try {
+                            matches.add(file.toURL());
+                        } catch (MalformedURLException ignored) {
+                        }
+                    }
+                }
+                return matches;
+            }
+        } else {
+            JarFile jarFile = null;
+            try {
+                jarFile = new JarFile(root);
+                URL baseURL = new URL("jar:" + root.toURL().toString() + "!/");
+                if (!hasWildcards(pattern)) {
+                    ZipEntry entry = jarFile.getEntry(pattern);
+                    if (entry != null) {
+                        URL match = new URL(baseURL, entry.getName());
+                        return Collections.singleton(match);
+                    } else {
+                        return Collections.emptySet();
+                    }
+                } else {
+                    Set<URL> matches = new LinkedHashSet<URL>();
+                    Enumeration entries = jarFile.entries();
+                    while (entries.hasMoreElements()) {
+                        ZipEntry entry = (ZipEntry) entries.nextElement();
+                        String fileName = entry.getName();
+                        if (matchPath(pattern, fileName)) {
+                            URL url = new URL(baseURL, fileName);
+                            matches.add(url);
+                        }
+                    }
+                    return matches;
+                }
+            } catch (IOException e) {
+                return Collections.emptySet();
+            } finally {
+                close(jarFile);
+            }
+        }
+    }
+
+    private static Map<String, File> listAllFileNames(File base) {
+        return listAllFileNames(base, "");
+    }
+
+    private static Map<String, File> listAllFileNames(File base, String prefix) {
+        if (!base.canRead() || !base.isDirectory()) {
+            throw new IllegalArgumentException(base.getAbsolutePath());
+        }
+        Map<String, File> map = new LinkedHashMap<String, File>();
+        File[] hits = base.listFiles();
+        for (File hit : hits) {
+            if (hit.canRead()) {
+                if (hit.isDirectory()) {
+                    map.putAll(listAllFileNames(hit, prefix.equals("") ? hit.getName() : prefix + "/" + hit.getName()));
+                } else {
+                    map.put(prefix.equals("") ? hit.getName() : prefix + "/" + hit.getName(), hit);
+                }
+            }
+        }
+        map.put(prefix, base);
+        return map;
+    }
+
+    private static void close(JarFile c) {
+        if (c != null) {
+            try {
+                c.close();
+            } catch (IOException e) {
+            }
+        }
+    }
+
+    /**
+     * Tests whether or not a given path matches a given pattern.
+     *
+     * @param pattern The pattern to match against. Must not be
+     *                <code>null</code>.
+     * @param str     The path to match, as a String. Must not be
+     *                <code>null</code>.
+     * @return <code>true</code> if the pattern matches against the string,
+     *         or <code>false</code> otherwise.
+     */
+    private static boolean matchPath(String pattern, String str) {
+        return matchPath(pattern, str, true);
+    }
+
+    /**
+     * Tests whether or not a given path matches a given pattern.
+     *
+     * @param pattern         The pattern to match against. Must not be
+     *                        <code>null</code>.
+     * @param str             The path to match, as a String. Must not be
+     *                        <code>null</code>.
+     * @param isCaseSensitive Whether or not matching should be performed
+     *                        case sensitively.
+     * @return <code>true</code> if the pattern matches against the string,
+     *         or <code>false</code> otherwise.
+     */
+    private static boolean matchPath(String pattern, String str,
+                                     boolean isCaseSensitive) {
+        String[] patDirs = tokenizePathAsArray(pattern);
+        String[] strDirs = tokenizePathAsArray(str);
+
+        int patIdxStart = 0;
+        int patIdxEnd = patDirs.length - 1;
+        int strIdxStart = 0;
+        int strIdxEnd = strDirs.length - 1;
+
+        // up to first '**'
+        while (patIdxStart <= patIdxEnd && strIdxStart <= strIdxEnd) {
+            String patDir = patDirs[patIdxStart];
+            if (patDir.equals("**")) {
+                break;
+            }
+            if (!match(patDir, strDirs[strIdxStart], isCaseSensitive)) {
+                patDirs = null;
+                strDirs = null;
+                return false;
+            }
+            patIdxStart++;
+            strIdxStart++;
+        }
+        if (strIdxStart > strIdxEnd) {
+            // String is exhausted
+            for (int i = patIdxStart; i <= patIdxEnd; i++) {
+                if (!patDirs[i].equals("**")) {
+                    patDirs = null;
+                    strDirs = null;
+                    return false;
+                }
+            }
+            return true;
+        } else {
+            if (patIdxStart > patIdxEnd) {
+                // String not exhausted, but pattern is. Failure.
+                patDirs = null;
+                strDirs = null;
+                return false;
+            }
+        }
+
+        // up to last '**'
+        while (patIdxStart <= patIdxEnd && strIdxStart <= strIdxEnd) {
+            String patDir = patDirs[patIdxEnd];
+            if (patDir.equals("**")) {
+                break;
+            }
+            if (!match(patDir, strDirs[strIdxEnd], isCaseSensitive)) {
+                patDirs = null;
+                strDirs = null;
+                return false;
+            }
+            patIdxEnd--;
+            strIdxEnd--;
+        }
+        if (strIdxStart > strIdxEnd) {
+            // String is exhausted
+            for (int i = patIdxStart; i <= patIdxEnd; i++) {
+                if (!patDirs[i].equals("**")) {
+                    patDirs = null;
+                    strDirs = null;
+                    return false;
+                }
+            }
+            return true;
+        }
+
+        while (patIdxStart != patIdxEnd && strIdxStart <= strIdxEnd) {
+            int patIdxTmp = -1;
+            for (int i = patIdxStart + 1; i <= patIdxEnd; i++) {
+                if (patDirs[i].equals("**")) {
+                    patIdxTmp = i;
+                    break;
+                }
+            }
+            if (patIdxTmp == patIdxStart + 1) {
+                // '**/**' situation, so skip one
+                patIdxStart++;
+                continue;
+            }
+            // Find the pattern between padIdxStart & padIdxTmp in str between
+            // strIdxStart & strIdxEnd
+            int patLength = (patIdxTmp - patIdxStart - 1);
+            int strLength = (strIdxEnd - strIdxStart + 1);
+            int foundIdx = -1;
+            strLoop:
+            for (int i = 0; i <= strLength - patLength; i++) {
+                for (int j = 0; j < patLength; j++) {
+                    String subPat = patDirs[patIdxStart + j + 1];
+                    String subStr = strDirs[strIdxStart + i + j];
+                    if (!match(subPat, subStr, isCaseSensitive)) {
+                        continue strLoop;
+                    }
+                }
+
+                foundIdx = strIdxStart + i;
+                break;
+            }
+
+            if (foundIdx == -1) {
+                patDirs = null;
+                strDirs = null;
+                return false;
+            }
+
+            patIdxStart = patIdxTmp;
+            strIdxStart = foundIdx + patLength;
+        }
+
+        for (int i = patIdxStart; i <= patIdxEnd; i++) {
+            if (!patDirs[i].equals("**")) {
+                patDirs = null;
+                strDirs = null;
+                return false;
+            }
+        }
+
+        return true;
+    }
+
+    /**
+     * Tests whether or not a string matches against a pattern.
+     * The pattern may contain two special characters:<br>
+     * '*' means zero or more characters<br>
+     * '?' means one and only one character
+     *
+     * @param pattern         The pattern to match against.
+     *                        Must not be <code>null</code>.
+     * @param str             The string which must be matched against the pattern.
+     *                        Must not be <code>null</code>.
+     * @param isCaseSensitive Whether or not matching should be performed
+     *                        case sensitively.
+     * @return <code>true</code> if the string matches against the pattern,
+     *         or <code>false</code> otherwise.
+     */
+    private static boolean match(String pattern, String str,
+                                 boolean isCaseSensitive) {
+        char[] patArr = pattern.toCharArray();
+        char[] strArr = str.toCharArray();
+        int patIdxStart = 0;
+        int patIdxEnd = patArr.length - 1;
+        int strIdxStart = 0;
+        int strIdxEnd = strArr.length - 1;
+        char ch;
+
+        boolean containsStar = false;
+        for (int i = 0; i < patArr.length; i++) {
+            if (patArr[i] == '*') {
+                containsStar = true;
+                break;
+            }
+        }
+
+        if (!containsStar) {
+            // No '*'s, so we make a shortcut
+            if (patIdxEnd != strIdxEnd) {
+                return false; // Pattern and string do not have the same size
+            }
+            for (int i = 0; i <= patIdxEnd; i++) {
+                ch = patArr[i];
+                if (ch != '?') {
+                    if (isCaseSensitive && ch != strArr[i]) {
+                        return false; // Character mismatch
+                    }
+                    if (!isCaseSensitive && Character.toUpperCase(ch)
+                            != Character.toUpperCase(strArr[i])) {
+                        return false;  // Character mismatch
+                    }
+                }
+            }
+            return true; // String matches against pattern
+        }
+
+        if (patIdxEnd == 0) {
+            return true; // Pattern contains only '*', which matches anything
+        }
+
+        // Process characters before first star
+        while ((ch = patArr[patIdxStart]) != '*' && strIdxStart <= strIdxEnd) {
+            if (ch != '?') {
+                if (isCaseSensitive && ch != strArr[strIdxStart]) {
+                    return false; // Character mismatch
+                }
+                if (!isCaseSensitive && Character.toUpperCase(ch)
+                        != Character.toUpperCase(strArr[strIdxStart])) {
+                    return false; // Character mismatch
+                }
+            }
+            patIdxStart++;
+            strIdxStart++;
+        }
+        if (strIdxStart > strIdxEnd) {
+            // All characters in the string are used. Check if only '*'s are
+            // left in the pattern. If so, we succeeded. Otherwise failure.
+            for (int i = patIdxStart; i <= patIdxEnd; i++) {
+                if (patArr[i] != '*') {
+                    return false;
+                }
+            }
+            return true;
+        }
+
+        // Process characters after last star
+        while ((ch = patArr[patIdxEnd]) != '*' && strIdxStart <= strIdxEnd) {
+            if (ch != '?') {
+                if (isCaseSensitive && ch != strArr[strIdxEnd]) {
+                    return false; // Character mismatch
+                }
+                if (!isCaseSensitive && Character.toUpperCase(ch)
+                        != Character.toUpperCase(strArr[strIdxEnd])) {
+                    return false; // Character mismatch
+                }
+            }
+            patIdxEnd--;
+            strIdxEnd--;
+        }
+        if (strIdxStart > strIdxEnd) {
+            // All characters in the string are used. Check if only '*'s are
+            // left in the pattern. If so, we succeeded. Otherwise failure.
+            for (int i = patIdxStart; i <= patIdxEnd; i++) {
+                if (patArr[i] != '*') {
+                    return false;
+                }
+            }
+            return true;
+        }
+
+        // process pattern between stars. padIdxStart and patIdxEnd point
+        // always to a '*'.
+        while (patIdxStart != patIdxEnd && strIdxStart <= strIdxEnd) {
+            int patIdxTmp = -1;
+            for (int i = patIdxStart + 1; i <= patIdxEnd; i++) {
+                if (patArr[i] == '*') {
+                    patIdxTmp = i;
+                    break;
+                }
+            }
+            if (patIdxTmp == patIdxStart + 1) {
+                // Two stars next to each other, skip the first one.
+                patIdxStart++;
+                continue;
+            }
+            // Find the pattern between padIdxStart & padIdxTmp in str between
+            // strIdxStart & strIdxEnd
+            int patLength = (patIdxTmp - patIdxStart - 1);
+            int strLength = (strIdxEnd - strIdxStart + 1);
+            int foundIdx = -1;
+            strLoop:
+            for (int i = 0; i <= strLength - patLength; i++) {
+                for (int j = 0; j < patLength; j++) {
+                    ch = patArr[patIdxStart + j + 1];
+                    if (ch != '?') {
+                        if (isCaseSensitive && ch != strArr[strIdxStart + i
+                                + j]) {
+                            continue strLoop;
+                        }
+                        if (!isCaseSensitive
+                                && Character.toUpperCase(ch)
+                                != Character.toUpperCase(strArr[strIdxStart + i + j])) {
+                            continue strLoop;
+                        }
+                    }
+                }
+
+                foundIdx = strIdxStart + i;
+                break;
+            }
+
+            if (foundIdx == -1) {
+                return false;
+            }
+
+            patIdxStart = patIdxTmp;
+            strIdxStart = foundIdx + patLength;
+        }
+
+        // All characters in the string are used. Check if only '*'s are left
+        // in the pattern. If so, we succeeded. Otherwise failure.
+        for (int i = patIdxStart; i <= patIdxEnd; i++) {
+            if (patArr[i] != '*') {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * Verifies that the specified filename represents an absolute path.
+     * Differs from new java.io.File("filename").isAbsolute() in that a path
+     * beginning with a double file separator--signifying a Windows UNC--must
+     * at minimum match "\\a\b" to be considered an absolute path.
+     *
+     * @param filename the filename to be checked.
+     * @return true if the filename represents an absolute path.
+     * @throws NullPointerException if filename is null.
+     * @since Ant 1.6.3
+     */
+    private static boolean isAbsolutePath(String filename) {
+        int len = filename.length();
+        if (len == 0) {
+            return false;
+        }
+        char sep = File.separatorChar;
+        filename = filename.replace('/', sep).replace('\\', sep);
+        char c = filename.charAt(0);
+        if (!(onDos || onNetWare)) {
+            return (c == sep);
+        }
+        if (c == sep) {
+            if (!(onDos && len > 4 && filename.charAt(1) == sep)) {
+                return false;
+            }
+            int nextsep = filename.indexOf(sep, 2);
+            return nextsep > 2 && nextsep + 1 < len;
+        }
+        int colon = filename.indexOf(':');
+        return (Character.isLetter(c) && colon == 1
+                && filename.length() > 2 && filename.charAt(2) == sep)
+                || (onNetWare && colon > 0);
+    }
+
+    /**
+     * Dissect the specified absolute path.
+     *
+     * @param path the path to dissect.
+     * @return String[] {root, remaining path}.
+     * @throws NullPointerException if path is null.
+     */
+    private static String[] dissect(String path) {
+        char sep = File.separatorChar;
+        path = path.replace('/', sep).replace('\\', sep);
+
+        // make sure we are dealing with an absolute path
+        if (!isAbsolutePath(path)) {
+            throw new IllegalArgumentException(path + " is not an absolute path");
+        }
+        String root = null;
+        int colon = path.indexOf(':');
+        if (colon > 0 && (onDos || onNetWare)) {
+
+            int next = colon + 1;
+            root = path.substring(0, next).toUpperCase();
+            char[] ca = path.toCharArray();
+            root += sep;
+            //remove the initial separator; the root has it.
+            next = (ca[next] == sep) ? next + 1 : next;
+
+            StringBuffer sbPath = new StringBuffer();
+            // Eliminate consecutive slashes after the drive spec:
+            for (int i = next; i < ca.length; i++) {
+                if (ca[i] != sep || ca[i - 1] != sep) {
+                    sbPath.append(ca[i]);
+                }
+            }
+            path = sbPath.toString();
+        } else if (path.length() > 1 && path.charAt(1) == sep) {
+            // UNC drive
+            int nextsep = path.indexOf(sep, 2);
+            nextsep = path.indexOf(sep, nextsep + 1);
+            root = (nextsep > 2) ? path.substring(0, nextsep + 1) : path;
+            path = path.substring(root.length());
+        } else {
+            root = File.separator;
+            path = path.substring(1);
+        }
+        return new String[]{root, path};
+    }
+
+
+    private static String[] tokenizePathAsArray(String path) {
+        String root = null;
+        if (isAbsolutePath(path)) {
+            String[] s = dissect(path);
+            root = s[0];
+            path = s[1];
+        }
+        char sep = File.separatorChar;
+        int start = 0;
+        int len = path.length();
+        int count = 0;
+        for (int pos = 0; pos < len; pos++) {
+            if (path.charAt(pos) == sep) {
+                if (pos != start) {
+                    count++;
+                }
+                start = pos + 1;
+            }
+        }
+        if (len != start) {
+            count++;
+        }
+        String[] l = new String[count + ((root == null) ? 0 : 1)];
+
+        if (root != null) {
+            l[0] = root;
+            count = 1;
+        } else {
+            count = 0;
+        }
+        start = 0;
+        for (int pos = 0; pos < len; pos++) {
+            if (path.charAt(pos) == sep) {
+                if (pos != start) {
+                    String tok = path.substring(start, pos);
+                    l[count++] = tok;
+                }
+                start = pos + 1;
+            }
+        }
+        if (len != start) {
+            String tok = path.substring(start);
+            l[count/*++*/] = tok;
+        }
+        return l;
+    }
+
+
+    /**
+     * Tests if a string contains stars or question marks
+     *
+     * @param input a String which one wants to test for containing wildcard
+     * @return true if the string contains at least a star or a question mark
+     */
+    private static boolean hasWildcards(String input) {
+        return (input.indexOf('*') != -1 || input.indexOf('?') != -1);
+    }
+
+}
+

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapLoader.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapLoader.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapLoader.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/BootstrapLoader.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,28 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+import java.util.Properties;
+
+/**
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+public interface BootstrapLoader {
+    void boot(String[] args, Properties properties, ClassLoader classLoader);
+}

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/ClassLoaderFactory.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/ClassLoaderFactory.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/ClassLoaderFactory.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/ClassLoaderFactory.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,29 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+import java.util.List;
+import java.net.URL;
+
+/**
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+public interface ClassLoaderFactory {
+    ClassLoader createClassLoader(ClassLoader parent, List<URL> urls);
+}

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/FatalStartupError.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/FatalStartupError.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/FatalStartupError.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/FatalStartupError.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,78 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+/**
+ * Indicates that a fatal error occured while starting the server.
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+public class FatalStartupError extends Error {
+    /**
+     * The default exit code assigned to new exception if an exit code is not provided.
+     */
+    public static final int DEFAULT_EXIT_CODE = 3;
+
+    private final int exitCode;
+
+    /**
+     * Creates a FatalStartupError containing the specified message and the DEFAULT_EXIT_CODE.
+     * @param message a descrption of the cause of the error
+     */
+    public FatalStartupError(String message) {
+        this(message, FatalStartupError.DEFAULT_EXIT_CODE);
+    }
+
+    /**
+     * Creates a FatalStartupError containing the specified message and exit code.
+     * @param message a descrption of the cause of the error
+     * @param exitCode the exit code that should be passed to System.exit(int)
+     */
+    public FatalStartupError(String message, int exitCode) {
+        super(message);
+        this.exitCode = exitCode;
+    }
+
+    /**
+     * Creates a FatalStartupError containing the specified message, cause by exception, and the DEFAULT_EXIT_CODE.
+     * @param message a descrption of the cause of the error
+     * @param cause the cause of this exception
+     */
+    public FatalStartupError(String message, Throwable cause) {
+        this(message, FatalStartupError.DEFAULT_EXIT_CODE, cause);
+    }
+
+    /**
+     * Creates a FatalStartupError containing the specified message, cause by exception, and the specified exit code.
+     * @param message a descrption of the cause of the error
+     * @param exitCode the exit code that should be passed to System.exit(int)
+     * @param cause the cause of this exception
+     */
+    public FatalStartupError(String message, int exitCode, Throwable cause) {
+        super(message, cause);
+        this.exitCode = exitCode;
+    }
+
+    /**
+     * Gets the number that should be passed to System.exit(int) when the virtual machine is halted.
+     * @return the exit code that should be passed to System.exit(int)
+     */
+    public int getExitCode() {
+        return exitCode;
+    }
+}

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/UrlClassLoaderFactory.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/UrlClassLoaderFactory.java?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/UrlClassLoaderFactory.java (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/java/org/apache/xbean/bootstrap/UrlClassLoaderFactory.java Mon Jul 10 21:39:36 2006
@@ -0,0 +1,33 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.xbean.bootstrap;
+
+import java.net.URL;
+import java.net.URLClassLoader;
+import java.util.List;
+
+/**
+ * @author Dain Sundstrom
+ * @version $Id$
+ * @since 2.5-colossus
+ */
+public class UrlClassLoaderFactory implements ClassLoaderFactory {
+    public ClassLoader createClassLoader(ClassLoader parent, List<URL> urls) {
+        URLClassLoader classLoader = new URLClassLoader(urls.toArray(new URL[urls.size()]), parent);
+        return classLoader;
+    }
+}

Added: geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/LICENSE
URL: http://svn.apache.org/viewvc/geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/LICENSE?rev=420719&view=auto
==============================================================================
--- geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/LICENSE (added)
+++ geronimo/xbean/branches/colossus/xbean-bootstrap/src/main/resources/META-INF/LICENSE Mon Jul 10 21:39:36 2006
@@ -0,0 +1,203 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+



Mime
View raw message