openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mprud...@apache.org
Subject svn commit: r477460 - in /incubator/openjpa/branches/0.9.6-incubating: openjpa-examples/ openjpa-lib/src/main/java/org/apache/openjpa/lib/util/ openjpa-persistence-jdbc/ openjpa-project/ src/site/apt/
Date Tue, 21 Nov 2006 01:30:34 GMT
Author: mprudhom
Date: Mon Nov 20 17:30:33 2006
New Revision: 477460

URL: http://svn.apache.org/viewvc?view=rev&rev=477460
Log:
Merged license and deployment changes into the 0.9.6-incubating branch for preparation for
a release

Modified:
    incubator/openjpa/branches/0.9.6-incubating/openjpa-examples/pom.xml
    incubator/openjpa/branches/0.9.6-incubating/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Localizer.java
    incubator/openjpa/branches/0.9.6-incubating/openjpa-persistence-jdbc/pom.xml
    incubator/openjpa/branches/0.9.6-incubating/openjpa-project/pom.xml
    incubator/openjpa/branches/0.9.6-incubating/openjpa-project/source-assembly.xml
    incubator/openjpa/branches/0.9.6-incubating/src/site/apt/building.apt
    incubator/openjpa/branches/0.9.6-incubating/src/site/apt/index.apt

Modified: incubator/openjpa/branches/0.9.6-incubating/openjpa-examples/pom.xml
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/openjpa-examples/pom.xml?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/openjpa-examples/pom.xml (original)
+++ incubator/openjpa/branches/0.9.6-incubating/openjpa-examples/pom.xml Mon Nov 20 17:30:33
2006
@@ -39,7 +39,7 @@
         <dependency>
             <groupId>org.apache.derby</groupId>
             <artifactId>derby</artifactId>
-            <version>10.1.3.1</version>
+            <version>10.2.1.6</version>
             <scope>test</scope>
         </dependency>
         <dependency>
@@ -51,7 +51,7 @@
         <dependency>
             <groupId>commons-collections</groupId>
             <artifactId>commons-collections</artifactId>
-            <version>3.1</version>
+            <version>3.2</version>
             <scope>test</scope>
         </dependency>
     </dependencies>

Modified: incubator/openjpa/branches/0.9.6-incubating/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Localizer.java
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Localizer.java?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Localizer.java
(original)
+++ incubator/openjpa/branches/0.9.6-incubating/openjpa-lib/src/main/java/org/apache/openjpa/lib/util/Localizer.java
Mon Nov 20 17:30:33 2006
@@ -77,12 +77,16 @@
         if (locale == null)
             locale = Locale.getDefault();
 
-        Package pkg = cls == null ? null : cls.getPackage();
+        int dot = (cls == null) ? -1 : cls.getName().lastIndexOf('.');
+        String pkg;
         String file;
-        if (pkg == null)
+        if (dot == -1) {
+            pkg = "";
             file = "localizer";
-        else
-            file = pkg.getName() + ".localizer";
+        } else {
+            pkg = cls.getName().substring(0, dot);
+            file = pkg + ".localizer";
+        }
         String key = file + locale.toString();
 
         // no locking; ok if bundle created multiple times
@@ -113,13 +117,13 @@
     }
 
     private String _file;
+    private String _pkg;
     private ResourceBundle _bundle = null;
-    private Package _package;
     private Locale _locale;
     private ClassLoader _loader;
 
-    private Localizer(Package p, String f, Locale locale, ClassLoader loader) {
-        _package = p;
+    private Localizer(String pkg, String f, Locale locale, ClassLoader loader) {
+        _pkg = pkg;
         _file = f;
         _locale = locale;
         _loader = loader;
@@ -212,7 +216,7 @@
      * @see #get(String)
      */
     public Message get(String key, Object[] subs) {
-        return new Message(_package, getBundle(), key, subs, false);
+        return new Message(_pkg, getBundle(), key, subs, false);
     }
 
     /**
@@ -224,7 +228,7 @@
      * @see #getFatal(String)
      */
     public Message getFatal(String key, Object[] subs) {
-        return new Message(_package, getBundle(), key, subs, true);
+        return new Message(_pkg, getBundle(), key, subs, true);
     }
 
     /**
@@ -234,17 +238,17 @@
      */
     public static class Message {
 
-        private final Package _package;
+        private final String _pkg;
         private final String _key;
         private final Object[] _subs;
         private final String _localizedMessage;
 
-        private Message(Package pkg, ResourceBundle bundle, String key, 
+        private Message(String packageName, ResourceBundle bundle, String key, 
             Object[] subs, boolean fatal) {
             if (bundle == null && fatal)
                 throw new MissingResourceException(key, key, key);
 
-            _package = pkg;
+            _pkg = packageName;
             _key = key;
             _subs = subs;
             if (bundle == null) {
@@ -282,13 +286,10 @@
             return _subs;
         }
 
-        /**
-         * Package containing localized resource for this message.
-         */
-        public Package getPackage() {
-            return _package;
+        public String getPackageName() {
+            return _pkg;
         }
-        
+
         public String toString() {
             return getMessage();
         }

Modified: incubator/openjpa/branches/0.9.6-incubating/openjpa-persistence-jdbc/pom.xml
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/openjpa-persistence-jdbc/pom.xml?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/openjpa-persistence-jdbc/pom.xml (original)
+++ incubator/openjpa/branches/0.9.6-incubating/openjpa-persistence-jdbc/pom.xml Mon Nov 20
17:30:33 2006
@@ -45,7 +45,7 @@
         <dependency>
             <groupId>org.apache.derby</groupId>
             <artifactId>derby</artifactId>
-            <version>10.1.3.1</version>
+            <version>10.2.1.6</version>
             <scope>test</scope>
         </dependency>
         <dependency>
@@ -57,7 +57,7 @@
         <dependency>
             <groupId>commons-collections</groupId>
             <artifactId>commons-collections</artifactId>
-            <version>3.1</version>
+            <version>3.2</version>
             <scope>test</scope>
         </dependency>
     </dependencies>

Modified: incubator/openjpa/branches/0.9.6-incubating/openjpa-project/pom.xml
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/openjpa-project/pom.xml?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/openjpa-project/pom.xml (original)
+++ incubator/openjpa/branches/0.9.6-incubating/openjpa-project/pom.xml Mon Nov 20 17:30:33
2006
@@ -343,7 +343,7 @@
         <dependency>
             <groupId>org.apache.derby</groupId>
             <artifactId>derby</artifactId>
-            <version>10.1.3.1</version>
+            <version>10.2.1.6</version>
         </dependency>
 
         <!-- jars needed for for docbook -->

Modified: incubator/openjpa/branches/0.9.6-incubating/openjpa-project/source-assembly.xml
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/openjpa-project/source-assembly.xml?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/openjpa-project/source-assembly.xml (original)
+++ incubator/openjpa/branches/0.9.6-incubating/openjpa-project/source-assembly.xml Mon Nov
20 17:30:33 2006
@@ -19,14 +19,44 @@
     <formats>
         <format>zip</format>
     </formats>
-    <includeBaseDirectory>true</includeBaseDirectory>
+    <!--
+        rather than including the base directory (which would cause this
+        archive to unpack into the same directory as the binary
+        distribution), we specify the directory into which to put
+        sources below, in the <outputDirectory> tags
+    -->
+    <includeBaseDirectory>false</includeBaseDirectory>
     <fileSets>
         <fileSet>
             <directory>..</directory>
-            <outputDirectory></outputDirectory>
+            <outputDirectory>${artifactId}-${version}-source</outputDirectory>
             <excludes>
                 <exclude>**/target/**</exclude>
             </excludes>
+        </fileSet>
+
+        <!--
+            Also put the standard license and notice files at the top
+            of the zip. Even those these will be included in the
+            openjpa-project sub-directory, the Apache rules say that
+            it needs to be in the top-level of the artifact. See:
+
+                http://www.apache.org/legal/src-headers.html#notice
+        -->
+        <fileSet>
+            <outputDirectory>${artifactId}-${version}-source</outputDirectory>
+            <includes>
+                <include>README</include>
+                <include>DISCLAIMER</include>
+                <include>LICENSE</include>
+                <include>STATUS</include>
+                <include>NOTICE</include>
+                <include>README.txt</include>
+                <include>DISCLAIMER.txt</include>
+                <include>LICENSE.txt</include>
+                <include>STATUS.txt</include>
+                <include>NOTICE.txt</include>
+            </includes>
         </fileSet>
     </fileSets>
 </assembly>

Modified: incubator/openjpa/branches/0.9.6-incubating/src/site/apt/building.apt
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/src/site/apt/building.apt?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/src/site/apt/building.apt (original)
+++ incubator/openjpa/branches/0.9.6-incubating/src/site/apt/building.apt Mon Nov 20 17:30:33
2006
@@ -1,3 +1,17 @@
+-- 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.
+
  ------
  openjpa
  ------

Modified: incubator/openjpa/branches/0.9.6-incubating/src/site/apt/index.apt
URL: http://svn.apache.org/viewvc/incubator/openjpa/branches/0.9.6-incubating/src/site/apt/index.apt?view=diff&rev=477460&r1=477459&r2=477460
==============================================================================
--- incubator/openjpa/branches/0.9.6-incubating/src/site/apt/index.apt (original)
+++ incubator/openjpa/branches/0.9.6-incubating/src/site/apt/index.apt Mon Nov 20 17:30:33
2006
@@ -1,3 +1,17 @@
+-- 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.
+
  ------
  openjpa
  ------



Mime
View raw message