svn commit: r557397 - in /jakarta/commons/proper/digester/trunk: build.properties.sample build.xml

2007-07-18 Thread bayard
Author: bayard
Date: Wed Jul 18 14:11:26 2007
New Revision: 557397

URL: http://svn.apache.org/viewvc?view=revrev=557397
Log:
The build.xml is simplified, using an include/exclude approach with the junit 
task rather than defining a task per test package. The build.properties.sample 
is updated to look in the local .maven by default, making it easier for the 
average committer to test the ant build out. See: DIGESTER-117

Modified:
jakarta/commons/proper/digester/trunk/build.properties.sample
jakarta/commons/proper/digester/trunk/build.xml

Modified: jakarta/commons/proper/digester/trunk/build.properties.sample
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/digester/trunk/build.properties.sample?view=diffrev=557397r1=557396r2=557397
==
--- jakarta/commons/proper/digester/trunk/build.properties.sample (original)
+++ jakarta/commons/proper/digester/trunk/build.properties.sample Wed Jul 18 
14:11:26 2007
@@ -1,57 +1,56 @@
-#
-# Ant configuration file
-#
-# When building Digester using Ant it is necessary to provide Ant with
-# some configuration information about the setup of the host machine on
-# which the build is happening. 
+#   Licensed to the Apache Software Foundation (ASF) under one or more
+#   contributor license agreements.  See the NOTICE file distributed with
+#   this work for additional information regarding copyright ownership.
+#   The ASF licenses this file to You 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.
+
+##
+# Sample Ant build.properties file
+#
+# This setup assumes dependent jars are in a local maven 1 repository.
+# However the jars are located, the properties ending in .jar need
+# expand to full paths to the jars.
 #
 # Copy this file (build.properties.sample) to build.properties then edit
 # entries below as appropriate before running any Ant commands.
-#
-#
+##
 
-# Specify a base directory where required jar files can be found.
-# Alternatively, provide complete paths to all of the needed libaries below.
+# Repository base path
+repository=${user.home}/.maven/repository
 
-root=/java/jars
+# JUnit
+junit.home=${repository}/junit/jars
+junit.jar=${junit.home}/junit-3.8.1.jar
 
+# XML parser
 # When using java 1.3 or earlier, JAXP is not included in the standard
 # libraries, so external jar files are required. If you are using Java
 # 1.4 or later, you can omit these libraries
-#
-# Note that when using xerces parser, the bundled xml-apis.jar provides the
-# same classes as Sun's jaxp.jar.
-
-jaxp.home=${root}
-jaxp.jaxp.jar=${jaxp.home}/jaxp.jar
-jaxp.parser.jar=${jaxp.home}/crimson.jar
-
-# Digester depends upon several other commons projects. 
-#
-# If you are building Digester from a checkout of the trunks-proper directory
-# and have already built the latest code for each of the dependent projects 
-# then these paths are automatically correct. 
-#
-# In other circumstances, provide direct paths (possibly based on ${root}
-# to all these required libraries.
-#
-# Note that Digester no longer depends on commons-collections itself; there is
-# a runtime dependency currently inherited from commons-beanutils, however.
-#
-# See file project.xml or RELEASE-NOTES.txt for the specific versions of these
-# files which are required.
-
-commons-beanutils.home=../beanutils/dist
-commons-beanutils.jar=${commons-beanutils.home}/commons-beanutils.jar
-commons-logging.home=../logging/dist
-commons-logging.jar=${commons-logging.home}/commons-logging.jar
-
-# JUnit is required if compiling/running the unit tests
-
-junit.jar=${root}/junit.jar
+jaxp.parser.home=${repository}/xerces/jars
+jaxp.parser.jar=${jaxp.parser.home}/xerces-2.0.2.jar
+jaxp.jaxp.home=${repository}/xml-apis/jars
+jaxp.jaxp.jar=${jaxp.jaxp.home}/xml-apis-1.0.b2.jar
+
+# Commons logging
+commons-logging.home=${repository}/commons-logging/jars
+commons-logging.jar=${commons-logging.home}/commons-logging-1.1.jar
+
+# Commons beanutils
+commons-beanutils.home=${repository}/commons-beanutils/jars
+commons-beanutils.jar=${commons-beanutils.home}/commons-beanutils-1.7.0.jar
 
 # The digester tests output logging information (including Exceptions

svn commit: r557404 - /jakarta/commons/proper/digester/trunk/build.xml

2007-07-18 Thread bayard
Author: bayard
Date: Wed Jul 18 14:37:11 2007
New Revision: 557404

URL: http://svn.apache.org/viewvc?view=revrev=557404
Log:
Applying Petteri Ra:ty's build.xml improvement from DIGESTER-89 so you can 
build the jar without the javadoc. I did modify it so you are forced to run the 
tests when building the jar

Modified:
jakarta/commons/proper/digester/trunk/build.xml

Modified: jakarta/commons/proper/digester/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/digester/trunk/build.xml?view=diffrev=557404r1=557403r2=557404
==
--- jakarta/commons/proper/digester/trunk/build.xml (original)
+++ jakarta/commons/proper/digester/trunk/build.xml Wed Jul 18 14:37:11 2007
@@ -256,20 +256,22 @@
 /javadoc
   /target
 
+  target name=jar depends=compile, test
+   description=Create commons-digester.jar
+mkdir  dir=${dist.home}/
+jarjarfile=${dist.home}/commons-${component.name}.jar
+basedir=${build.home}/classes
+   manifest=${build.home}/conf/MANIFEST.MF/
+  /target
 
-  target name=dist depends=compile,javadoc
+  target name=dist depends=jar,javadoc
description=Create binary distribution
-mkdir  dir=${dist.home}/
 copy  file=LICENSE.txt
   todir=${dist.home}/
-mkdir  dir=${build.home}/classes/META-INF/
 copy  file=RELEASE-NOTES.txt
   todir=${dist.home}/
 copy  file=NOTICE.txt
   todir=${dist.home}/
-jarjarfile=${dist.home}/commons-${component.name}.jar
-basedir=${build.home}/classes
-   manifest=${build.home}/conf/MANIFEST.MF/
   /target
 
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r557415 - /jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java

2007-07-18 Thread bayard
Author: bayard
Date: Wed Jul 18 15:15:21 2007
New Revision: 557415

URL: http://svn.apache.org/viewvc?view=revrev=557415
Log:
Fixing 'avfter' to 'after' typo as per DAEMON-101

Modified:

jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java

Modified: 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java?view=diffrev=557415r1=557414r2=557415
==
--- 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
 (original)
+++ 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
 Wed Jul 18 15:15:21 2007
@@ -75,7 +75,7 @@
  * method has been successfully invoked and possibly the security
  * level of the JVM has been dropped.  codeImplementors of this
  * method are free to start any number of threads, but need to
- * return control avfter having done that to enable invocation of
+ * return control after having done that to enable invocation of
  * the stop()-method.
  */
 public void start()



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r557416 - /jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java

2007-07-18 Thread bayard
Author: bayard
Date: Wed Jul 18 15:16:26 2007
New Revision: 557416

URL: http://svn.apache.org/viewvc?view=revrev=557416
Log:
Also removing unnecessary code tag as per DAEMON-101

Modified:

jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java

Modified: 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java?view=diffrev=557416r1=557415r2=557416
==
--- 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
 (original)
+++ 
jakarta/commons/proper/daemon/trunk/src/java/org/apache/commons/daemon/Daemon.java
 Wed Jul 18 15:16:26 2007
@@ -73,7 +73,7 @@
  * Start the operation of this codeDaemon/code instance. This
  * method is to be invoked by the environment after the init()
  * method has been successfully invoked and possibly the security
- * level of the JVM has been dropped.  codeImplementors of this
+ * level of the JVM has been dropped. Implementors of this
  * method are free to start any number of threads, but need to
  * return control after having done that to enable invocation of
  * the stop()-method.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r557008 - in /jakarta/commons/proper/beanutils/trunk/src: java/org/apache/commons/beanutils/PropertyUtilsBean.java test/org/apache/commons/beanutils/Jira92TestCase.java

2007-07-17 Thread bayard
Author: bayard
Date: Tue Jul 17 11:27:26 2007
New Revision: 557008

URL: http://svn.apache.org/viewvc?view=revrev=557008
Log:
Applying Niall's test and fix from BEANUTILS-92 - with my suggested changes of 
an improved debug message and a simplified test case

Added:

jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils/Jira92TestCase.java
Modified:

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java

Modified: 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java?view=diffrev=557008r1=557007r2=557008
==
--- 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java
 (original)
+++ 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java
 Tue Jul 17 11:27:26 2007
@@ -241,11 +241,17 @@
 for (int i = 0; i  origDescriptors.length; i++) {
 String name = origDescriptors[i].getName();
 if (isReadable(orig, name)  isWriteable(dest, name)) {
-Object value = ((DynaBean) orig).get(name);
-if (dest instanceof DynaBean) {
-((DynaBean) dest).set(name, value);
-} else {
-setSimpleProperty(dest, name, value);
+try {
+Object value = ((DynaBean) orig).get(name);
+if (dest instanceof DynaBean) {
+((DynaBean) dest).set(name, value);
+} else {
+setSimpleProperty(dest, name, value);
+}
+} catch (NoSuchMethodException e) {
+if (log.isDebugEnabled()) {
+log.debug(Error writing to ' + name + ' on 
class ' + dest.getClass() + ', e);
+}
 }
 }
 }
@@ -254,11 +260,17 @@
 while (names.hasNext()) {
 String name = (String) names.next();
 if (isWriteable(dest, name)) {
-Object value = ((Map) orig).get(name);
-if (dest instanceof DynaBean) {
-((DynaBean) dest).set(name, value);
-} else {
-setSimpleProperty(dest, name, value);
+try {
+Object value = ((Map) orig).get(name);
+if (dest instanceof DynaBean) {
+((DynaBean) dest).set(name, value);
+} else {
+setSimpleProperty(dest, name, value);
+}
+} catch (NoSuchMethodException e) {
+if (log.isDebugEnabled()) {
+log.debug(Error writing to ' + name + ' on 
class ' + dest.getClass() + ', e);
+}
 }
 }
 }
@@ -268,11 +280,17 @@
 for (int i = 0; i  origDescriptors.length; i++) {
 String name = origDescriptors[i].getName();
 if (isReadable(orig, name)  isWriteable(dest, name)) {
-Object value = getSimpleProperty(orig, name);
-if (dest instanceof DynaBean) {
-((DynaBean) dest).set(name, value);
-} else {
-setSimpleProperty(dest, name, value);
+try {
+Object value = getSimpleProperty(orig, name);
+if (dest instanceof DynaBean) {
+((DynaBean) dest).set(name, value);
+} else {
+setSimpleProperty(dest, name, value);
+}
+} catch (NoSuchMethodException e) {
+if (log.isDebugEnabled()) {
+log.debug(Error writing to ' + name + ' on 
class ' + dest.getClass() + ', e);
+}
 }
 }
 }

Added: 
jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils/Jira92TestCase.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils/Jira92TestCase.java?view=autorev=557008
==
--- 
jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils/Jira92TestCase.java
 (added)
+++ 
jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils

svn commit: r557022 - /jakarta/commons/README.txt

2007-07-17 Thread bayard
Author: bayard
Date: Tue Jul 17 11:47:35 2007
New Revision: 557022

URL: http://svn.apache.org/viewvc?view=revrev=557022
Log:
Adding a bit of doc on how our SVN is set up, and how to edit the svn:externals

Added:
jakarta/commons/README.txt

Added: jakarta/commons/README.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/README.txt?view=autorev=557022
==
--- jakarta/commons/README.txt (added)
+++ jakarta/commons/README.txt Tue Jul 17 11:47:35 2007
@@ -0,0 +1,33 @@
+Commons SVN information
+===
+
+Commons is split up into three subsections:
+
+Proper
+Released components, developed and maintained by Commons committers.
+Sandbox
+In development components, any Apache committer may request access. 
+Sandbox components move to Proper before a release.
+Dormant
+Inactive unreleased components. Sandbox components that didn't make 
+it end up here. To bring a component back from dormancy, bring the 
+subject up on the mailing list.
+
+
+
+Each of the above contains many atomic components which may be checked 
+out individually:
+
+svn co 
https://svn.apache.org/repos/asf/jakarta/commons/[subsection]/[component]/trunk 
[component]
+
+To check all of the components in a subsection out at the same time, 
+trunks-[subsection] directories are provided as a convenience. This is 
+done via svn:externals. 
+
+
+
+To add or remove an entry to the svn:externals, do the following:
+
+svn co -N https://svn.apache.org/repos/asf/jakarta/commons/trunks-[subsection]
+svn propedit svn:externals trunks-[subsection]
+svn ci -m Adding/removing Foo to [subsection] trunks-[subsection]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r557031 - /jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java

2007-07-17 Thread bayard
Author: bayard
Date: Tue Jul 17 12:12:54 2007
New Revision: 557031

URL: http://svn.apache.org/viewvc?view=revrev=557031
Log:
Refernece - Reference

Modified:

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java

Modified: 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java?view=diffrev=557031r1=557030r2=557031
==
--- 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java
 (original)
+++ 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java
 Tue Jul 17 12:12:54 2007
@@ -61,7 +61,7 @@
 protected Map propertiesMap = new HashMap();
 
 /**
- * Cross Refernece for column name -- dyna property name
+ * Cross Reference for column name -- dyna property name
  * (needed when lowerCase option is true)
  */
 private Map columnNameXref;



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r556774 - /jakarta/commons/proper/lang/trunk/xdocs/index.xml

2007-07-16 Thread bayard
Author: bayard
Date: Mon Jul 16 17:00:42 2007
New Revision: 556774

URL: http://svn.apache.org/viewvc?view=revrev=556774
Log:
Sadly the Chinese translation has followed the German translation into 404ity. 
Removing that link

Modified:
jakarta/commons/proper/lang/trunk/xdocs/index.xml

Modified: jakarta/commons/proper/lang/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/xdocs/index.xml?view=diffrev=556774r1=556773r2=556774
==
--- jakarta/commons/proper/lang/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/lang/trunk/xdocs/index.xml Mon Jul 16 17:00:42 2007
@@ -89,7 +89,6 @@
 li
 Oct 17, 2003 - a href=http://www.builder.com/;Builder.com/a has an 
article on Commons Lang v1.0 entitled
 a 
href=http://builder.com.com/article.jhtml?id=u00320021017yan01.htmamp;page=1amp;vf=tt;Jakarta
 Commons Lang project offers centralized utility functions/a
-[and in a 
href=http://www.zdnet.com.cn/developer/tech/story/0,281602,39077840,00.htm;chinese/a].
 /li
 li
 a href=http://ant.apache.org;Ant/a,



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r556775 - /jakarta/commons/proper/lang/trunk/xdocs/index.xml

2007-07-16 Thread bayard
Author: bayard
Date: Mon Jul 16 17:01:23 2007
New Revision: 556775

URL: http://svn.apache.org/viewvc?view=revrev=556775
Log:
Builder.com indicates this was written in 2002, not 2003

Modified:
jakarta/commons/proper/lang/trunk/xdocs/index.xml

Modified: jakarta/commons/proper/lang/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/xdocs/index.xml?view=diffrev=556775r1=556774r2=556775
==
--- jakarta/commons/proper/lang/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/lang/trunk/xdocs/index.xml Mon Jul 16 17:01:23 2007
@@ -87,7 +87,7 @@
 section name=Resources
 ul
 li
-Oct 17, 2003 - a href=http://www.builder.com/;Builder.com/a has an 
article on Commons Lang v1.0 entitled
+Oct 17, 2002 - a href=http://www.builder.com/;Builder.com/a has an 
article on Commons Lang v1.0 entitled
 a 
href=http://builder.com.com/article.jhtml?id=u00320021017yan01.htmamp;page=1amp;vf=tt;Jakarta
 Commons Lang project offers centralized utility functions/a
 /li
 li



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r556229 - in /jakarta/commons/proper/beanutils/trunk/src: java/org/apache/commons/beanutils/ java/org/apache/commons/beanutils/converters/ java/org/apache/commons/beanutils/locale/ test/or

2007-07-14 Thread bayard
Author: bayard
Date: Fri Jul 13 23:11:19 2007
New Revision: 556229

URL: http://svn.apache.org/viewvc?view=revrev=556229
Log:
Fixing to the common idiom of 'String[]' and not 'String var[]'

Modified:

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BasicDynaClass.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BeanUtilsBean.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/ConvertUtils.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/ConvertUtilsBean.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/JDBCDynaClass.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/MappedPropertyDescriptor.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/MethodUtils.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/PropertyUtilsBean.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/ResultSetDynaClass.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/WrapDynaClass.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/BooleanArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/ByteArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/CharacterArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/DoubleArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/FloatArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/IntegerArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/LongArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/ShortArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/StringArrayConverter.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/locale/LocaleBeanUtilsBean.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/locale/LocaleConvertUtils.java

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/locale/LocaleConvertUtilsBean.java

jakarta/commons/proper/beanutils/trunk/src/test/org/apache/commons/beanutils/TestBean.java

Modified: 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BasicDynaClass.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BasicDynaClass.java?view=diffrev=556229r1=556228r2=556229
==
--- 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BasicDynaClass.java
 (original)
+++ 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BasicDynaClass.java
 Fri Jul 13 23:11:19 2007
@@ -74,7 +74,7 @@
  * @param properties Property descriptors for the supported properties
  */
 public BasicDynaClass(String name, Class dynaBeanClass,
-  DynaProperty properties[]) {
+  DynaProperty[] properties) {
 
 super();
 if (name != null) {
@@ -105,14 +105,14 @@
  * The method signature of the constructor we will use to create
  * new DynaBean instances.
  */
-protected static Class constructorTypes[] = { DynaClass.class };
+protected static Class[] constructorTypes = { DynaClass.class };
 
 
 /**
  * The argument values to be passed to the constructore we will use
  * to create new DynaBean instances.
  */
-protected Object constructorValues[] = { this };
+protected Object[] constructorValues = { this };
 
 
 /**
@@ -131,7 +131,7 @@
 /**
  * The set of dynamic properties that are part of this DynaClass.
  */
-protected DynaProperty properties[] = new DynaProperty[0];
+protected DynaProperty[] properties = new DynaProperty[0];
 
 
 /**
@@ -290,7 +290,7 @@
  *
  * @param properties List of dynamic properties to be supported
  */
-protected void setProperties(DynaProperty properties[]) {
+protected void setProperties(DynaProperty[] properties) {
 
 this.properties = properties;
 propertiesMap.clear();

Modified: 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BeanUtilsBean.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/BeanUtilsBean.java?view

svn commit: r556227 - /jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java

2007-07-13 Thread bayard
Author: bayard
Date: Fri Jul 13 22:54:29 2007
New Revision: 556227

URL: http://svn.apache.org/viewvc?view=revrev=556227
Log:
Fixing to the common idiom of 'String[]' and not 'String var[]'

Modified:

jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java

Modified: 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java?view=diffrev=556227r1=556226r2=556227
==
--- 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java
 (original)
+++ 
jakarta/commons/proper/beanutils/trunk/src/java/org/apache/commons/beanutils/converters/AbstractArrayConverter.java
 Fri Jul 13 22:54:29 2007
@@ -99,7 +99,7 @@
 /**
  * pModel object for string arrays./p
  */
-protected static final String strings[] = new String[0];
+protected static final String[] strings = new String[0];
 
 
 /**



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r555705 - in /jakarta/commons/proper/dbcp/trunk: build.properties.sample build.xml src/test/org/apache/commons/dbcp/TestAll.java src/test/org/apache/commons/dbcp/TestJndi.java

2007-07-12 Thread bayard
Author: bayard
Date: Thu Jul 12 10:52:28 2007
New Revision: 555705

URL: http://svn.apache.org/viewvc?view=revrev=555705
Log:
Applying my patch from DBCP-227 - it's easy enough to run 'maven ant' if 
someone decides to do that someday, so no reason not to improve the existing 
build.xml in the meantime

Modified:
jakarta/commons/proper/dbcp/trunk/build.properties.sample
jakarta/commons/proper/dbcp/trunk/build.xml

jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestAll.java

jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJndi.java

Modified: jakarta/commons/proper/dbcp/trunk/build.properties.sample
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/build.properties.sample?view=diffrev=555705r1=555704r2=555705
==
--- jakarta/commons/proper/dbcp/trunk/build.properties.sample (original)
+++ jakarta/commons/proper/dbcp/trunk/build.properties.sample Thu Jul 12 
10:52:28 2007
@@ -48,8 +48,8 @@
 naming-java.jar=${naming.home}/naming-java-5.0.28.jar 
 
 # Commons logging - dependency of naming jars
-logging.home=${repository}/commons-logging/jars
-logging.jar=${logging.home}/commons-logging-1.0.4.jar
+commons-logging.home=${repository}/commons-logging/jars
+commons-logging.jar=${commons-logging.home}/commons-logging-1.0.4.jar
 
 # JTA - needed for managed connections
 
jta-spec.jar=${repository}/org.apache.geronimo.specs/jars/geronimo-jta_1.1_spec-1.1.jar

Modified: jakarta/commons/proper/dbcp/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/build.xml?view=diffrev=555705r1=555704r2=555705
==
--- jakarta/commons/proper/dbcp/trunk/build.xml (original)
+++ jakarta/commons/proper/dbcp/trunk/build.xml Thu Jul 12 10:52:28 2007
@@ -176,14 +176,15 @@
/target
 
target name=test depends=compile-test description=runs (junit) unit 
tests
-  java classname=${test.runner} fork=yes 
failonerror=${test.failonerror}
-arg value=${test.entry}/ 
+  echo message=${classpath}/
+  junit printsummary=true showoutput=true fork=yes 
haltonfailure=${test.failonerror}
 classpath
   pathelement location=${build.classes.dir} / 
   pathelement location=${build.test-classes.dir} / 
   pathelement path=${classpath} / 
 /classpath
-  /java
+test name=${test.entry}/ 
+  /junit
/target
 
target name=build-jar depends=compile
@@ -211,4 +212,4 @@
 
target name=dist depends=build description=gump target/

-/project
\ No newline at end of file
+/project

Modified: 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestAll.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestAll.java?view=diffrev=555705r1=555704r2=555705
==
--- 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestAll.java 
(original)
+++ 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestAll.java 
Thu Jul 12 10:52:28 2007
@@ -21,6 +21,7 @@
 import org.apache.commons.dbcp.datasources.TestSharedPoolDataSource;
 import org.apache.commons.dbcp.datasources.TestPerUserPoolDataSource;
 import org.apache.commons.dbcp.datasources.TestFactory;
+import org.apache.commons.jocl.TestJOCLContentHandler;
 
 /**
  * @author Rodney Waldhoff
@@ -47,6 +48,9 @@
 suite.addTest(TestSharedPoolDataSource.suite());
 suite.addTest(TestPerUserPoolDataSource.suite());
 suite.addTest(TestFactory.suite());
+suite.addTest(TestJOCLContentHandler.suite());
+suite.addTest(TestPoolingDataSource.suite());
+suite.addTest(TestJndi.suite());
 return suite;
 }
 

Modified: 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJndi.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJndi.java?view=diffrev=555705r1=555704r2=555705
==
--- 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJndi.java
 (original)
+++ 
jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJndi.java
 Thu Jul 12 10:52:28 2007
@@ -24,7 +24,9 @@
 import javax.naming.NamingException;
 import javax.sql.DataSource;
 
+import junit.framework.Test;
 import junit.framework.TestCase;
+import junit.framework.TestSuite;
 
 import org.apache.commons.dbcp.datasources.SharedPoolDataSource;
 import org.apache.commons.dbcp.datasources.PerUserPoolDataSource;
@@ -55,6 +57,10 @@
  */
 public TestJndi(String name) {
 super(name);
+}
+
+public static Test suite() {
+return new TestSuite(TestJndi.class

svn commit: r554448 - /jakarta/commons/proper/cli/tags/cli-1.1/

2007-07-08 Thread bayard
Author: bayard
Date: Sun Jul  8 14:41:16 2007
New Revision: 554448

URL: http://svn.apache.org/viewvc?view=revrev=554448
Log:
Stamping the actual release using RC3

Added:
jakarta/commons/proper/cli/tags/cli-1.1/
  - copied from r554447, jakarta/commons/proper/cli/tags/cli-1.1-RC3/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r554452 - /jakarta/commons/trunks-proper/

2007-07-08 Thread bayard
Author: bayard
Date: Sun Jul  8 14:50:24 2007
New Revision: 554452

URL: http://svn.apache.org/viewvc?view=revrev=554452
Log:
Removing cli-1.0.x from the live trunk list

Modified:
jakarta/commons/trunks-proper/   (props changed)

Propchange: jakarta/commons/trunks-proper/
--
--- svn:externals (original)
+++ svn:externals Sun Jul  8 14:50:24 2007
@@ -3,7 +3,6 @@
 betwixt https://svn.apache.org/repos/asf/jakarta/commons/proper/betwixt/trunk
 chain https://svn.apache.org/repos/asf/jakarta/commons/proper/chain/trunk
 cli https://svn.apache.org/repos/asf/jakarta/commons/proper/cli/trunk
-cli-1.0.x 
https://svn.apache.org/repos/asf/jakarta/commons/proper/cli/branches/cli-1.0.x
 codec https://svn.apache.org/repos/asf/jakarta/commons/proper/codec/trunk
 collections 
https://svn.apache.org/repos/asf/jakarta/commons/proper/collections/trunk
 commons-build 
https://svn.apache.org/repos/asf/jakarta/commons/proper/commons-build/trunk



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r553927 - /jakarta/commons/proper/lang/trunk/pom.xml

2007-07-06 Thread bayard
Author: bayard
Date: Fri Jul  6 08:24:13 2007
New Revision: 553927

URL: http://svn.apache.org/viewvc?view=revrev=553927
Log:
Upgrading to the parent v3 (and testing commit after karma changes)

Modified:
jakarta/commons/proper/lang/trunk/pom.xml

Modified: jakarta/commons/proper/lang/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/pom.xml?view=diffrev=553927r1=553926r2=553927
==
--- jakarta/commons/proper/lang/trunk/pom.xml (original)
+++ jakarta/commons/proper/lang/trunk/pom.xml Fri Jul  6 08:24:13 2007
@@ -22,7 +22,7 @@
   parent
 groupIdorg.apache.commons/groupId
 artifactIdcommons-parent/artifactId
-version1/version
+version3/version
   /parent
   modelVersion4.0.0/modelVersion
   groupIdcommons-lang/groupId



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r553680 - in /jakarta/commons/proper/beanutils/trunk: build.properties.sample build.xml

2007-07-05 Thread bayard
Author: bayard
Date: Thu Jul  5 17:57:18 2007
New Revision: 553680

URL: http://svn.apache.org/viewvc?view=revrev=553680
Log:
Fixing the build to include all the tests as per BEANUTILS-287. Also fixing the 
build.properties.sample so it's easier to use for the default maven user (ie: 
it looks by default in the .maven repository)

Modified:
jakarta/commons/proper/beanutils/trunk/build.properties.sample
jakarta/commons/proper/beanutils/trunk/build.xml

Modified: jakarta/commons/proper/beanutils/trunk/build.properties.sample
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/build.properties.sample?view=diffrev=553680r1=553679r2=553680
==
--- jakarta/commons/proper/beanutils/trunk/build.properties.sample (original)
+++ jakarta/commons/proper/beanutils/trunk/build.properties.sample Thu Jul  5 
17:57:18 2007
@@ -13,14 +13,20 @@
 #  See the License for the specific language governing permissions and
 #  limitations under the License.
 
+# Repository base path
+repository=${user.home}/.maven/repository
+
 # The pathname of the collections classes JAR file
-commons-collections.jar = commons-collections.jar
+commons-collections.home=${repository}/commons-collections/jars
+commons-collections.jar=${commons-collections.home}/commons-collections-3.2.jar
 
 # The pathname of the Commons Logging JAR file
-commons-logging.jar = commons-logging.jar
+commons-logging.home=${repository}/commons-logging/jars
+commons-logging.jar=${commons-logging.home}/commons-logging-1.1.jar
 
 # The pathname of the junit.jar JAR file
-junit.jar = junit.jar
+junit.home=${repository}/junit/jars
+junit.jar=${junit.home}/junit-3.8.1.jar
 
 # Configuration Example for Commons Logging in maven
 maven.junit.fork=true

Modified: jakarta/commons/proper/beanutils/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/beanutils/trunk/build.xml?view=diffrev=553680r1=553679r2=553680
==
--- jakarta/commons/proper/beanutils/trunk/build.xml (original)
+++ jakarta/commons/proper/beanutils/trunk/build.xml Thu Jul  5 17:57:18 2007
@@ -253,341 +253,17 @@
 !-- == Unit Test Targets = --
 
 
-  target name=test  depends=compile.tests,
-test.basic.dynabean,
-test.wrap.dynabean,
-test.dyna.property,
-test.property,
-test.dyna.bean,
-test.bean,
-test.convert,
-test.method,
-test.dyna.result,
-test.dyna.row,
-test.locale.convert,
-test.converters,
-test.beanification,
-test.lazy.dynaclass,
-test.lazy.dynabean,
-test.lazy.dynamap,
-test.lazy.dynalist,
-test.dynabean.mapdecorator,
-test.dynaproperty,
-test.indexed.properties,
-test.mapped.properties
-   
+ target name=test depends=compile.tests
description=Run all unit test cases
-  /target
-
-
-  target name=test.basic.dynabean depends=compile.tests
-echo message=Running BasicDynaBean tests .../
-java classname=${test.runner} fork=yes
-failonerror=${test.failonerror}
-  sysproperty key=org.apache.commons.logging.LogFactory
- value=${test.factory}/
-  sysproperty key=org.apache.commons.logging.Log
- value=${test.log}/
-  sysproperty key=org.apache.commons.logging.simplelog.defaultlog
- value=${test.level}/
-  arg value=org.apache.commons.beanutils.BasicDynaBeanTestCase/
-  classpath refid=test.classpath/
-/java
-  /target
-
-  target name=test.wrap.dynabean depends=compile.tests
-echo message=Running WrapDynaBean tests .../
-java classname=${test.runner} fork=yes
-failonerror=${test.failonerror}
-  sysproperty key=org.apache.commons.logging.LogFactory
- value=${test.factory}/
-  sysproperty key=org.apache.commons.logging.Log
- value=${test.log}/
-  sysproperty key=org.apache.commons.logging.simplelog.defaultlog
- value=${test.level}/
-  arg value=org.apache.commons.beanutils.WrapDynaBeanTestCase/
-  classpath refid=test.classpath/
-/java
-  /target
-
-  target name=test.dyna.property depends=compile.tests
-echo message=Running DynaBean PropertyUtils tests .../
-java classname=${test.runner} fork=yes

svn commit: r553359 - /jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

2007-07-04 Thread bayard
Author: bayard
Date: Wed Jul  4 18:35:30 2007
New Revision: 553359

URL: http://svn.apache.org/viewvc?view=revrev=553359
Log:
Adding newly dealt with issues

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt?view=diffrev=553359r1=553358r2=553359
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt Wed Jul  4 
18:35:30 2007
@@ -54,3 +54,8 @@
   CLI-71  - A weakness of parser. 
   CLI-129 - CLI_1_BRANCH build.xml doesn't work. 
   CLI-130 - Remove the Commons Lang dependency. 
+  CLI-131 - Options class returns options in random order. 
+  CLI-132 - MissingOptionException should contain a useful error message. 
+  CLI-133 - NullPointerException in Util.stripLeadingHyphens when passed a 
null argument. 
+  CLI-134 - 1.1 is not backwards compatible because it adds methods to the 
CommandLineParser interface. 
+  CLI-135 - Backwards compatibility between 1.1 and 1.0 broken due to 
Option.addValue removal. 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r553360 - /jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

2007-07-04 Thread bayard
Author: bayard
Date: Wed Jul  4 18:38:03 2007
New Revision: 553360

URL: http://svn.apache.org/viewvc?view=revrev=553360
Log:
Latest 'maven ant' run

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml?view=diffrev=553360r1=553359r2=553360
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml Wed Jul  4 18:38:03 
2007
@@ -1,7 +1,7 @@
 ?xml version=1.0 encoding=UTF-8?
 
 !--build.xml generated by maven from project.xml version 1.1
-  on date June 11 2007, time 2220--
+  on date July 4 2007, time 1837--
 
 project default=jar name=commons-cli basedir=.
   property name=defaulttargetdir value=target
@@ -51,6 +51,14 @@
   classpath refid=build.classpath
   /classpath
 /javac
+mkdir dir=${classesdir}/META-INF
+/mkdir
+copy todir=${classesdir}/META-INF
+  fileset dir=.
+include name=NOTICE.txt
+/include
+  /fileset
+/copy
   /target
   target name=jar description=o Create the jar depends=compile,test
 jar jarfile=${defaulttargetdir}/${final.name}.jar 
excludes=**/package.html basedir=${classesdir}
@@ -130,7 +138,7 @@
   format pattern=2002- property=year
   /format
 /tstamp
-property name=copyright value=Copyright amp;copy; 2002-2007 Apache 
Software Foundation. All Rights Reserved.
+property name=copyright value=Copyright amp;copy;  Apache Software 
Foundation. All Rights Reserved.
 /property
 property name=title value=CLI 1.1 API
 /property
@@ -155,4 +163,4 @@
 unjar dest=${maven.home} src=${user.home}/maven-install-latest.jar
 /unjar
   /target
-/project
+/project
\ No newline at end of file



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r553364 - /jakarta/commons/proper/cli/tags/cli-1.1-RC3/

2007-07-04 Thread bayard
Author: bayard
Date: Wed Jul  4 19:43:05 2007
New Revision: 553364

URL: http://svn.apache.org/viewvc?view=revrev=553364
Log:
Preparing RC3

Added:
jakarta/commons/proper/cli/tags/cli-1.1-RC3/
  - copied from r553363, jakarta/commons/proper/cli/branches/cli-1.0.x/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r552600 - /jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

2007-07-02 Thread bayard
Author: bayard
Date: Mon Jul  2 14:40:53 2007
New Revision: 552600

URL: http://svn.apache.org/viewvc?view=revrev=552600
Log:
Updating release notes to match the website

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt?view=diffrev=552600r1=552599r2=552600
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt Mon Jul  2 
14:40:53 2007
@@ -7,24 +7,20 @@
 
 INTRODUCTION:
 
-This document contains the release notes for this version of the Commons
-CLI package. Commons CLI provides a simple API for working with the command 
line arguments and options.
+This document contains the release notes for this version of the Commons CLI 
package. Commons CLI provides a simple API for working with the command line 
arguments and options.
 
-This is a bugfix release of CLI. Some parts are not backwards compatible:
+CLI 1.1 is a bugfix release of CLI. The following changes notable API changes 
were made: 
 
-* The CommandLineParser interface has two additional methods. If you were 
extending this, 
-  then you will need to add methods to your classes. If you were extending the 
abstract 
-  Parser class, then you should be okay. 
-* The HelpFormatter class had publicly accessible fields. These are now 
accessed via 
-  get/set methods.
-* Two of HelpFormatter's methods no longer throw IllegalArgumentException.
-* The Option class is no longer cloneable, and no longer has an 
addValue(String) method.
+ * The Parser abstract class has two additional parse methods that take a 
Properties parameter. 
+ * The HelpFormatter class had publicly accessible fields. These should now be 
accessed via get/set methods and the public fields are deprecated. 
+ * The Option class addValue(String) method now throws 
UnsupportedOperationException. 
+ * OptionValidator is a newly added class. 
+ * Option's now have equals(Object) and hashCode() methods. 
+ * The Option class also received two new methods, setDescription(String) and 
hasValueSeparator();boolean. 
 
-The best way to test any of the above is to recompile your code against CLI 
1.1. All 
-should result in compile time errors.
+The jar should be API backwards compatible, though if you were calling 
addValue(String) then you won't be happy. Please let us know your use case if 
that is so. 
 
-For more information, read the documentation on the project site at 
-http://jakarta.apache.org/commons/cli/
+For more information, read the documentation on the project site at 
http://jakarta.apache.org/commons/cli/
 
 NEW FEATURES:
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r552190 - /jakarta/commons/proper/cli/tags/cli-1.1-RC2/

2007-06-30 Thread bayard
Author: bayard
Date: Sat Jun 30 11:14:26 2007
New Revision: 552190

URL: http://svn.apache.org/viewvc?view=revrev=552190
Log:
Preparing a second release candidate

Added:
jakarta/commons/proper/cli/tags/cli-1.1-RC2/
  - copied from r552189, jakarta/commons/proper/cli/branches/cli-1.0.x/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r552192 - in /jakarta/commons/proper/cli/trunk/xdocs: changes.xml upgrading-1.0-to-1.1.xml

2007-06-30 Thread bayard
Author: bayard
Date: Sat Jun 30 11:26:35 2007
New Revision: 552192

URL: http://svn.apache.org/viewvc?view=revrev=552192
Log:
Upgrading release notes

Modified:
jakarta/commons/proper/cli/trunk/xdocs/changes.xml
jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/changes.xml?view=diffrev=552192r1=552191r2=552192
==
--- jakarta/commons/proper/cli/trunk/xdocs/changes.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/changes.xml Sat Jun 30 11:26:35 2007
@@ -47,6 +47,11 @@
   action type=fix issue=CLI-35HelpFormatter doesn't sort options 
properly. /action
   action type=fix issue=CLI-130Remove the Commons Lang dependency. 
/action
   action type=add issue=CLI-78Setting description of a Option. 
/action
+  action type=fix issue=CLI-131Options class returns options in 
random order. /action
+  action type=fix issue=CLI-132MissingOptionException should contain 
a useful error message. /action
+  action type=fix issue=CLI-133NullPointerException in 
Util.stripLeadingHyphens when passed a null argument. /action
+  action type=fix issue=CLI-1341.1 is not backwards compatible 
because it adds methods to the CommandLineParser interface. /action
+  action type=fix issue=CLI-135Backwards compatibility between 1.1 
and 1.0 broken due to Option.addValue removal. /action
 
 /release   
 

Modified: jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml?view=diffrev=552192r1=552191r2=552192
==
--- jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml Sat Jun 30 
11:26:35 2007
@@ -23,20 +23,21 @@
 body
 !-- == --
 section name=Upgrading from 1.0 to 1.1
-  pCLI 1.1 is a bugfix release of CLI. The following changes were not 
backward compatible: /p
+  pCLI 1.1 is a bugfix release of CLI. The following changes notable API 
changes were made: /p
 
   ul
-liThe CommandLineParser interface has two additional methods. If you 
were extending this,
-then you will need to add methods to your classes. If you were 
extending the abstract
-Parser class, then you should be okay. /li
-liThe HelpFormatter class had publicly accessible fields. These are now 
accessed via
-get/set methods. /li
-liTwo of HelpFormatter's methods no longer throw 
IllegalArgumentException. /li
-liThe Option class is no longer cloneable, and no longer has an 
addValue(String) method. /li
+liThe Parser abstract class has two additional parse methods that take a 
Properties parameter. /li
+liThe HelpFormatter class had publicly accessible fields. These should 
now be accessed via
+get/set methods and the public fields are deprecated. /li
+liThe Option class addValue(String) method now throws 
UnsupportedOperationException. /li
+liOptionValidator is a newly added class. /li
+liOption's now have equals(Object) and hashCode() methods. /li
+liThe Option class also received two new methods, setDescription(String) 
and hasValueSeparator();boolean. /li
   /ul
 
-  pThe best way to test any of the above is to recompile your code against 
CLI 1.1. All of the above 
-  should result in compile time errors. /p
+  pThe jar should be API backwards compatible, though if you were calling 
addValue(String) then you won't be happy. Please 
+ let us know your use case if that is so. /p
+
 /section
 section name=Bugs fixed in 1.1
   pThe list of bugs fixed in 1.1 may be seen via the 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r552194 - /jakarta/commons/proper/cli/trunk/xdocs/changes.xml

2007-06-30 Thread bayard
Author: bayard
Date: Sat Jun 30 11:30:44 2007
New Revision: 552194

URL: http://svn.apache.org/viewvc?view=revrev=552194
Log:
Sorted

Modified:
jakarta/commons/proper/cli/trunk/xdocs/changes.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/changes.xml?view=diffrev=552194r1=552193r2=552194
==
--- jakarta/commons/proper/cli/trunk/xdocs/changes.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/changes.xml Sat Jun 30 11:30:44 2007
@@ -24,29 +24,29 @@
 release version=1.1 date=2007-?-?
   description=This is a maintenance release containing bug fixes. 
 
-  action type=fix issue=CLI-51Parameter value -something 
misinterpreted as a parameter. /action
-  action type=fix issue=CLI-129CLI_1_BRANCH build.xml doesn't work. 
/action
-  action type=fix issue=CLI-59No Javadoc for HelpFormatter!. 
/action
-  action type=fix issue=CLI-29Options should not be able to be added 
more than once. /action
-  action type=fix issue=CLI-28Infinite Loop in Command-Line 
processing. /action
-  action type=fix issue=CLI-45Documentation errors. /action
-  action type=fix issue=CLI-71A weakness of parser. /action
-  action type=fix issue=CLI-13CommandLine.getOptionValue() behaves 
contrary to docs. /action
+  action type=fix issue=CLI-2Wrong usage summary. /action
   action type=fix issue=CLI-5Dependecy on commons-lang-2.0 but 
commons-lang-1.0 is obtained. /action
-  action type=fix issue=CLI-44Document enhancement. /action
-  action type=fix issue=CLI-69Error parsing option arguments. 
/action
-  action type=fix issue=CLI-38HelpFormatter doesn't function 
correctly for options with only LongOpt. /action
   action type=fix issue=CLI-8Line separator as first char for 
helpformatter (footer) throws exception. /action
-  action type=fix issue=CLI-67Missing arguments in 
HelpFormatter.renderOptions(..). /action
-  action type=fix issue=CLI-26Only long options without short option 
seems to be noticed. /action
-  action type=fix issue=CLI-65Parser breaks up command line parms 
into single characters. /action
-  action type=fix issue=CLI-23Passing properties in Parser does not 
work for options with a single argument. /action
-  action type=fix issue=CLI-2Wrong usage summary. /action
+  action type=fix issue=CLI-13CommandLine.getOptionValue() behaves 
contrary to docs. /action
   action type=fix issue=CLI-21clone method in Option should use 
super.clone(). /action
-  action type=fix issue=CLI-56clone() method doesn't fully clone 
contents. /action
+  action type=fix issue=CLI-23Passing properties in Parser does not 
work for options with a single argument. /action
+  action type=fix issue=CLI-26Only long options without short option 
seems to be noticed. /action
+  action type=fix issue=CLI-28Infinite Loop in Command-Line 
processing. /action
+  action type=fix issue=CLI-29Options should not be able to be added 
more than once. /action
   action type=fix issue=CLI-35HelpFormatter doesn't sort options 
properly. /action
-  action type=fix issue=CLI-130Remove the Commons Lang dependency. 
/action
+  action type=fix issue=CLI-38HelpFormatter doesn't function 
correctly for options with only LongOpt. /action
+  action type=fix issue=CLI-44Document enhancement. /action
+  action type=fix issue=CLI-45Documentation errors. /action
+  action type=fix issue=CLI-51Parameter value -something 
misinterpreted as a parameter. /action
+  action type=fix issue=CLI-56clone() method doesn't fully clone 
contents. /action
+  action type=fix issue=CLI-59No Javadoc for HelpFormatter!. 
/action
+  action type=fix issue=CLI-65Parser breaks up command line parms 
into single characters. /action
+  action type=fix issue=CLI-67Missing arguments in 
HelpFormatter.renderOptions(..). /action
+  action type=fix issue=CLI-69Error parsing option arguments. 
/action
+  action type=fix issue=CLI-71A weakness of parser. /action
   action type=add issue=CLI-78Setting description of a Option. 
/action
+  action type=fix issue=CLI-129CLI_1_BRANCH build.xml doesn't work. 
/action
+  action type=fix issue=CLI-130Remove the Commons Lang dependency. 
/action
   action type=fix issue=CLI-131Options class returns options in 
random order. /action
   action type=fix issue=CLI-132MissingOptionException should contain 
a useful error message. /action
   action type=fix issue=CLI-133NullPointerException in 
Util.stripLeadingHyphens when passed a null argument. /action



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551811 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/CommandLineParser.java test/org/apache/commons/cli/GnuParseTest.java test/org/apache/commons/cl

2007-06-29 Thread bayard
Author: bayard
Date: Thu Jun 28 23:50:39 2007
New Revision: 551811

URL: http://svn.apache.org/viewvc?view=revrev=551811
Log:
Removing the two new methods from the CommandLineParser interface as per CLI-134

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java?view=diffrev=551811r1=551810r2=551811
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
 Thu Jun 28 23:50:39 2007
@@ -68,9 +68,13 @@
  * @throws ParseException if there are any problems encountered
  * while parsing the command line tokens.
  */
+/* To maintain binary compatibility, this is commented out. 
+   It is still in the abstract Parser class, so most users will 
+   still reap the benefit. 
 CommandLine parse(Options options, String[] arguments, 
   boolean stopAtNonOption)
throws ParseException;
+ */
 
 /**
  * Parse the arguments according to the specified options and
@@ -85,7 +89,11 @@
  * @throws ParseException if there are any problems encountered
  * while parsing the command line tokens.
  */
+/* To maintain binary compatibility, this is commented out. 
+   It is still in the abstract Parser class, so most users will 
+   still reap the benefit. 
 CommandLine parse(Options options, String[] arguments, 
   Properties properties, boolean stopAtNonOption)
throws ParseException;
-}
\ No newline at end of file
+ */
+}

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java?view=diffrev=551811r1=551810r2=551811
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java
 Thu Jun 28 23:50:39 2007
@@ -23,7 +23,7 @@
 public class GnuParseTest extends TestCase
 {
 private Options _options = null;
-private CommandLineParser _parser = null;
+private Parser _parser = null;
 
 public static Test suite() { 
 return new TestSuite( GnuParseTest.class ); 

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java?view=diffrev=551811r1=551810r2=551811
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java
 Thu Jun 28 23:50:39 2007
@@ -24,7 +24,7 @@
 {
 
 private Options _options = null;
-private CommandLineParser _parser = null;
+private Parser _parser = null;
 
 public static Test suite() { 
 return new TestSuite(ParseTest.class); 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551821 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

2007-06-29 Thread bayard
Author: bayard
Date: Fri Jun 29 00:29:41 2007
New Revision: 551821

URL: http://svn.apache.org/viewvc?view=revrev=551821
Log:
Adding some javadoc

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=551821r1=551820r2=551821
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Fri Jun 29 00:29:41 2007
@@ -632,6 +632,16 @@
 return result;
 }
 
+/**
+ * A rather odd clone method - due to incorrect code in 1.0 it is public 
+ * and in 1.1 rather than throwing a CloneNotSupportedException it throws 
+ * a RuntimeException so as to maintain backwards compat at the API level. 
+ *
+ * After calling this method, it is very likely you will want to call 
+ * clearValues(). 
+ *
+ * @throws RuntimeException
+ */
 public Object clone() {
 try {
 Option option = (Option) super.clone();
@@ -653,6 +663,12 @@
 this.values.clear();
 }
 
+/**
+ * This method is not intended to be used. It was a piece of internal 
+ * API that was made public in 1.0. It currently throws an 
UnsupportedOperationException. 
+ * @deprecated
+ * @throws UnsupportedOperationException
+ */
 public boolean addValue(String value) {
 throw new UnsupportedOperationException(
The addValue method is not intended for client use.  + 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551815 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/Option.java java/org/apache/commons/cli/Parser.java test/org/apache/commons/cli/OptionTest.java

2007-06-29 Thread bayard
Author: bayard
Date: Fri Jun 29 00:08:44 2007
New Revision: 551815

URL: http://svn.apache.org/viewvc?view=revrev=551815
Log:
Applying the patch from CLI-135 to put the public addValue method back, even 
though it just throws an exception. This maintains binary compatibility, for 
some level of compatibility. 

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=551815r1=551814r2=551815
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Fri Jun 29 00:08:44 2007
@@ -401,7 +401,7 @@
  * 
  * @param value is a/the value of this Option
  */
-void addValue(String value)
+void addValueForProcessing(String value)
 {
 switch (numberOfArgs)
 {
@@ -647,6 +647,13 @@
  */
 void clearValues() {
 this.values.clear();
+}
+
+public boolean addValue(Object object) {
+throw new UnsupportedOperationException(
+   The addValue method is not intended for client use.  + 
+   Subclasses should use the addValueForProcessing method instead. 
+   );
 }
 
 }

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java?view=diffrev=551815r1=551814r2=551815
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 Fri Jun 29 00:08:44 2007
@@ -258,7 +258,7 @@
 {
 try
 {
-opt.addValue(value);
+opt.addValueForProcessing(value);
 }
 catch (RuntimeException exp)
 {
@@ -340,7 +340,7 @@
 // found a value
 try
 {
-opt.addValue( Util.stripLeadingAndTrailingQuotes(str) );
+opt.addValueForProcessing( 
Util.stripLeadingAndTrailingQuotes(str) );
 }
 catch (RuntimeException exp)
 {

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java?view=diffrev=551815r1=551814r2=551815
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 Fri Jun 29 00:08:44 2007
@@ -23,8 +23,18 @@
  */
 public class OptionTest extends TestCase {
 
+   private static class TestOption extends Option {
+public TestOption(String opt, boolean hasArg, String description) 
throws IllegalArgumentException {
+super(opt, hasArg, description);
+}
+public boolean addValue(String value) {
+addValueForProcessing(value);
+return true;
+}
+   }
+
public void testClear() {
-   Option option = new Option(x, true, );
+   TestOption option = new TestOption(x, true, );
assertEquals(0, option.getValuesList().size());
option.addValue(a);
assertEquals(1, option.getValuesList().size());
@@ -34,8 +44,8 @@
 
 // See http://issues.apache.org/jira/browse/CLI-21
 public void testClone() throws CloneNotSupportedException {
-Option a = new Option(a, true, );
-Option b = (Option) a.clone();
+TestOption a = new TestOption(a, true, );
+TestOption b = (TestOption) a.clone();
 assertEquals(a, b);
 assertNotSame(a, b);
 a.setDescription(a);



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551816 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

2007-06-29 Thread bayard
Author: bayard
Date: Fri Jun 29 00:10:22 2007
New Revision: 551816

URL: http://svn.apache.org/viewvc?view=revrev=551816
Log:
Applying second patch from CLI-135 - fixing the mistake of having an Object and 
not a String as the parameter to addValue. 

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=551816r1=551815r2=551816
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Fri Jun 29 00:10:22 2007
@@ -649,7 +649,7 @@
 this.values.clear();
 }
 
-public boolean addValue(Object object) {
+public boolean addValue(String value) {
 throw new UnsupportedOperationException(
The addValue method is not intended for client use.  + 
Subclasses should use the addValueForProcessing method instead. 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551819 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

2007-06-29 Thread bayard
Author: bayard
Date: Fri Jun 29 00:16:42 2007
New Revision: 551819

URL: http://svn.apache.org/viewvc?view=revrev=551819
Log:
Applying the second patch from CLI-21 - moving the clone method back to public 
and hiding the exception. 

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=551819r1=551818r2=551819
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Fri Jun 29 00:16:42 2007
@@ -632,10 +632,14 @@
 return result;
 }
 
-protected Object clone() throws CloneNotSupportedException {
-Option option = (Option) super.clone();
-option.values = new ArrayList(values);
-return option;
+public Object clone() {
+try {
+Option option = (Option) super.clone();
+option.values = new ArrayList(values);
+return option;
+} catch(CloneNotSupportedException cnse) {
+throw new RuntimeException(A CloneNotSupportedException was 
thrown:  + cnse.getMessage());
+}
 }
 
 /**



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r551813 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/CommandLineParser.java test/org/apache/commons/cli/ValueTest.java

2007-06-29 Thread bayard
Author: bayard
Date: Thu Jun 28 23:54:58 2007
New Revision: 551813

URL: http://svn.apache.org/viewvc?view=revrev=551813
Log:
The previous commit removed an incorrect method. This puts it back and removes 
the right one, along with a fix for a unit test that fails to compile as a 
result. See CLI-134

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java?view=diffrev=551813r1=551812r2=551813
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java
 Thu Jun 28 23:54:58 2007
@@ -52,9 +52,13 @@
  * @throws ParseException if there are any problems encountered
  * while parsing the command line tokens.
  */
+/* To maintain binary compatibility, this is commented out. 
+   It is still in the abstract Parser class, so most users will 
+   still reap the benefit. 
 CommandLine parse(Options options, String[] arguments, 
   Properties properties)
throws ParseException;
+ */
 
 /**
  * Parse the arguments according to the specified options.
@@ -68,13 +72,9 @@
  * @throws ParseException if there are any problems encountered
  * while parsing the command line tokens.
  */
-/* To maintain binary compatibility, this is commented out. 
-   It is still in the abstract Parser class, so most users will 
-   still reap the benefit. 
 CommandLine parse(Options options, String[] arguments, 
   boolean stopAtNonOption)
throws ParseException;
- */
 
 /**
  * Parse the arguments according to the specified options and

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java?view=diffrev=551813r1=551812r2=551813
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java
 Thu Jun 28 23:54:58 2007
@@ -91,7 +91,7 @@
 
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 _cl = parser.parse(opts,args);
 }
 catch (ParseException e)
@@ -137,7 +137,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(e) );
 assertNull( cmd.getOptionValue(e) );
@@ -154,7 +154,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(e) );
 assertEquals( everything, cmd.getOptionValue(e) );
@@ -171,7 +171,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(fish) );
 assertNull( cmd.getOptionValue(fish) );
@@ -188,7 +188,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(fish) );
 assertEquals( face, cmd.getOptionValue(fish) );
@@ -205,7 +205,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(j) );
 assertEquals( ink, cmd.getOptionValue(j) );
@@ -225,7 +225,7 @@
 };
 try
 {
-CommandLineParser parser = new PosixParser();
+Parser parser = new PosixParser();
 CommandLine cmd = parser.parse(opts,args);
 assertTrue( cmd.hasOption(gravy) );
 assertEquals( gold, cmd.getOptionValue(gravy) );
@@ -245,7

svn commit: r547721 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/Option.java test/org/apache/commons/cli/OptionTest.java

2007-06-15 Thread bayard
Author: bayard
Date: Fri Jun 15 08:51:35 2007
New Revision: 547721

URL: http://svn.apache.org/viewvc?view=revrev=547721
Log:
Applying Brian Egge's patch to CLI-21 that resurrects the clone() method

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=547721r1=547720r2=547721
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Fri Jun 15 08:51:35 2007
@@ -33,7 +33,7 @@
  * @author a href=mailto:[EMAIL PROTECTED]James Strachan/a
  * @version $Revision$
  */
-public class Option {
+public class Option implements Cloneable {
 
 /** constant that specifies the number of argument values has 
 not been specified */
@@ -630,6 +630,12 @@
 result = ( opt != null ? opt.hashCode() : 0 );
 result = 31 * result + ( longOpt != null ? longOpt.hashCode() : 0 );
 return result;
+}
+
+protected Object clone() throws CloneNotSupportedException {
+Option option = (Option) super.clone();
+option.values = new ArrayList(values);
+return option;
 }
 
 /**

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java?view=diffrev=547721r1=547720r2=547721
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 Fri Jun 15 08:51:35 2007
@@ -31,5 +31,42 @@
option.clearValues();
assertEquals(0, option.getValuesList().size());
}
-
+
+// See http://issues.apache.org/jira/browse/CLI-21
+public void testClone() throws CloneNotSupportedException {
+Option a = new Option(a, true, );
+Option b = (Option) a.clone();
+assertEquals(a, b);
+assertNotSame(a, b);
+a.setDescription(a);
+assertEquals(, b.getDescription());
+b.setArgs(2);
+b.addValue(b1);
+b.addValue(b2);
+assertEquals(1, a.getArgs());
+assertEquals(0, a.getValuesList().size());
+assertEquals(2, b.getValues().length);
+}
+
+private static class DefaultOption extends Option {
+
+private final String defaultValue;
+
+public DefaultOption(String opt, String description, String 
defaultValue) throws IllegalArgumentException {
+super(opt, true, description);
+this.defaultValue = defaultValue;
+}
+
+public String getValue() {
+return super.getValue() != null ? super.getValue() : defaultValue;
+}
+}
+
+public void testSubclass() throws CloneNotSupportedException {
+Option option = new DefaultOption(f, file, myfile.txt);
+Option clone = (Option) option.clone();
+assertEquals(myfile.txt, clone.getValue());
+assertEquals(DefaultOption.class, clone.getClass());
+}
+
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546992 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java

2007-06-13 Thread bayard
Author: bayard
Date: Wed Jun 13 11:29:45 2007
New Revision: 546992

URL: http://svn.apache.org/viewvc?view=revrev=546992
Log:
Moved the attributes back to being public fields so as to maintain backwards 
compatibility. Each one has been deprecated, with the deprecation meaning we'll 
move them to private scope rather than remove them. 

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java?view=diffrev=546992r1=546991r2=546992
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
 Wed Jun 13 11:29:45 2007
@@ -40,7 +40,10 @@
 /** default padding to the left of each line */
 public static final int DEFAULT_LEFT_PAD = 1;
 
-/** ?? */
+/**
+ * the number of characters of padding to be prefixed
+ * to each description line
+ */
 public static final int DEFAULT_DESC_PAD = 3;
 
 /** the string to display at the begining of the usage statement */
@@ -57,29 +60,62 @@
 
 // -- 
Attributes
 
-/** number of characters per line */
-private int defaultWidth = DEFAULT_WIDTH;
-
-/** amount of padding to the left of each line */
-private int defaultLeftPad = DEFAULT_LEFT_PAD;
-
-/** ?? */
-private int defaultDescPad = DEFAULT_DESC_PAD;
-
-/** the string to display at the begining of the usage statement */
-private String defaultSyntaxPrefix = DEFAULT_SYNTAX_PREFIX;
-
-/** the new line character/string ?? */
-private String defaultNewLine = System.getProperty(line.separator);
-
-/** the shortOpt prefix */
-private String defaultOptPrefix = DEFAULT_OPT_PREFIX;
-
-/** the long Opt prefix */
-private String defaultLongOptPrefix = DEFAULT_LONG_OPT_PREFIX;
-
-/** the name of the argument */
-private String defaultArgName = DEFAULT_ARG_NAME;
+/**
+ * number of characters per line
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public int defaultWidth = DEFAULT_WIDTH;
+
+/**
+ * amount of padding to the left of each line
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public int defaultLeftPad = DEFAULT_LEFT_PAD;
+
+/**
+ * the number of characters of padding to be prefixed
+ * to each description line
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public int defaultDescPad = DEFAULT_DESC_PAD;
+
+/**
+ * the string to display at the begining of the usage statement
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public String defaultSyntaxPrefix = DEFAULT_SYNTAX_PREFIX;
+
+/**
+ * the new line string
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public String defaultNewLine = System.getProperty(line.separator);
+
+/**
+ * the shortOpt prefix
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public String defaultOptPrefix = DEFAULT_OPT_PREFIX;
+
+/**
+ * the long Opt prefix
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public String defaultLongOptPrefix = DEFAULT_LONG_OPT_PREFIX;
+
+/**
+ * the name of the argument
+ *
+ * @deprecated Scope will be made private for next major version
+ */
+public String defaultArgName = DEFAULT_ARG_NAME;
 
 /**
  * Sets the 'width'.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546544 - /jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 09:00:35 2007
New Revision: 546544

URL: http://svn.apache.org/viewvc?view=revrev=546544
Log:
Updating readme

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt?view=diffrev=546544r1=546543r2=546544
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/README.txt Tue Jun 12 
09:00:35 2007
@@ -12,7 +12,7 @@
 
   http://www.junit.org/
 
-There are two ways to build CLI, either with ant or maven.
+There are two ways to build CLI, either with Ant or Maven 1.
 
 Ant can be found here :
 
@@ -22,18 +22,17 @@
 
   ant dist
 
-Maven can be found here :
+Maven 1 can be found here :
 
   http://maven.apache.org
 
 and to build and test the system use:
 
-  maven jar:jar
+  maven clean jar
 
 The system will build and test itself.
 
-For complete documentation and to create a local copy of the
-CLI project website, type:
+For complete documentation type:
 
   maven site
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546558 - in /jakarta/commons/proper/cli/branches/cli-1.0.x: RELEASE-NOTES.txt maven.xml project.properties

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 09:22:51 2007
New Revision: 546558

URL: http://svn.apache.org/viewvc?view=revrev=546558
Log:
Adding release notes, and making the src dist end with -src/

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt
jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml
jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt?view=diffrev=546558r1=546557r2=546558
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt Tue Jun 12 
09:22:51 2007
@@ -1,7 +1,7 @@
 $Id$
 
Commons CLI Package
-  Version 1.0
+  Version 1.1
Release Notes
 
 
@@ -10,17 +10,40 @@
 This document contains the release notes for this version of the Commons
 CLI package. Commons CLI provides a simple API for working with the command 
line arguments and options.
 
-This is the first release of the CLI component, therefore all features are 
new, 
-there are no bug-fixes, nothing is deprecated and there are no changes.
+This is a bugfix release of CLI. 
 
 For more information, read the documentation on the project site at 
 http://jakarta.apache.org/commons/cli/
 
 NEW FEATURES:
 
+  CLI-78 - Setting description of a Option. 
+
 BUG FIXES:
 
 DEPRECATIONS:
 
 CHANGES: 
 
+  CLI-2   - Wrong usage summary. 
+  CLI-5   - Dependecy on commons-lang-2.0 but commons-lang-1.0 is obtained. 
+  CLI-8   - Line separator as first char for helpformatter (footer) throws 
exception. 
+  CLI-13  - CommandLine.getOptionValue() behaves contrary to docs. 
+  CLI-21  - clone method in Option should use super.clone(). 
+  CLI-23  - Passing properties in Parser does not work for options with a 
single argument. 
+  CLI-26  - Only long options without short option seems to be noticed. 
+  CLI-28  - Infinite Loop in Command-Line processing. 
+  CLI-29  - Options should not be able to be added more than once. 
+  CLI-35  - HelpFormatter doesn't sort options properly. 
+  CLI-38  - HelpFormatter doesn't function correctly for options with only 
LongOpt. 
+  CLI-44  - Document enhancement. 
+  CLI-45  - Documentation errors. 
+  CLI-51  - Parameter value -something misinterpreted as a parameter. 
+  CLI-56  - clone() method doesn't fully clone contents. 
+  CLI-59  - No Javadoc for HelpFormatter!. 
+  CLI-65  - Parser breaks up command line parms into single characters. 
+  CLI-67  - Missing arguments in HelpFormatter.renderOptions(..). 
+  CLI-69  - Error parsing option arguments. 
+  CLI-71  - A weakness of parser. 
+  CLI-129 - CLI_1_BRANCH build.xml doesn't work. 
+  CLI-130 - Remove the Commons Lang dependency. 

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml?view=diffrev=546558r1=546557r2=546558
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml Tue Jun 12 09:22:51 
2007
@@ -14,21 +14,25 @@
 See the License for the specific language governing permissions and
 limitations under the License.
 --
-project default=jar:jar
+project default=jar:jar
+  xmlns:j=jelly:core
 
-  !-- Ensures that the conf directory and NOTICE.txt are included in the
+  !-- Ensures that the release notes and NOTICE.txt are included in the
source distro.
--
   postGoal name=dist:prepare-src-filesystem
+j:set var=maven.dist.src.assembly.dir 
value=${pom.getPluginContext('maven-dist-plugin').getVariable('maven.dist.src.assembly.dir')}
 /
 copy todir=${maven.dist.src.assembly.dir}
   fileset file=${basedir}/NOTICE.txt/
+  fileset file=${basedir}/RELEASE-NOTES.txt/
 /copy
   /postGoal
 
-  !-- Ensures that NOTICE.txt is added to the binary distro --
+  !-- Ensures that release notes NOTICE.txt is added to the binary distro --
   preGoal name=dist:build-bin
 copy todir=${maven.dist.bin.assembly.dir}
   fileset file=${basedir}/NOTICE.txt/
+  fileset file=${basedir}/RELEASE-NOTES.txt/
 /copy
   /preGoal
 

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties?view=diffrev=546558r1=546557r2=546558
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties Tue Jun 12 
09:22:51 2007
@@ -16,6 +16,9

svn commit: r546583 - /jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 11:25:30 2007
New Revision: 546583

URL: http://svn.apache.org/viewvc?view=revrev=546583
Log:
Adding the Javadoc to state that getLoginTimeout and setLoginTimeout are NOT 
supported by BasicDataSource as per DBCP-218

Modified:

jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java

Modified: 
jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java?view=diffrev=546583r1=546582r2=546583
==
--- 
jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java
 (original)
+++ 
jakarta/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/BasicDataSource.java
 Tue Jun 12 11:25:30 2007
@@ -882,8 +882,7 @@
 
 
 /**
- * strongBasicDataSource does NOT support this method.
- * /strong
+ * strongBasicDataSource does NOT support this method. /strong
  *
  * @param username Database user on whose behalf the Connection
  *   is being made
@@ -902,6 +901,8 @@
 
 
 /**
+ * strongBasicDataSource does NOT support this method. /strong
+ *
  * pReturns the login timeout (in seconds) for connecting to the 
database.
  * /p
  * pCalls [EMAIL PROTECTED] #createDataSource()}, so has the side effect
@@ -913,7 +914,10 @@
  * @return login timeout in seconds
  */
 public int getLoginTimeout() throws SQLException {
-return createDataSource().getLoginTimeout();
+// This method isn't supported by the PoolingDataSource returned by
+// the createDataSource
+throw new UnsupportedOperationException(Not supported by 
BasicDataSource);
+//return createDataSource().getLoginTimeout();
 }
 
 
@@ -932,6 +936,8 @@
 
 
 /**
+ * strongBasicDataSource does NOT support this method. /strong
+ *
  * pSet the login timeout (in seconds) for connecting to the
  * database./p
  * p
@@ -939,10 +945,15 @@
  * of initializing the connection pool./p
  *
  * @param loginTimeout The new login timeout, or zero for no timeout
+ * @throws UnsupportedOperationException If the DataSource implementation
+ *   does not support the login timeout feature.
  * @throws SQLException if a database access error occurs
  */
 public void setLoginTimeout(int loginTimeout) throws SQLException {
-createDataSource().setLoginTimeout(loginTimeout);
+// This method isn't supported by the PoolingDataSource returned by
+// the createDataSource
+throw new UnsupportedOperationException(Not supported by 
BasicDataSource);
+//createDataSource().setLoginTimeout(loginTimeout);
 }
 
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546584 - in /jakarta/commons/proper/dbcp/trunk: pom.xml src/test/org/apache/commons/dbcp/TestJOCLed.java

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 11:28:57 2007
New Revision: 546584

URL: http://svn.apache.org/viewvc?view=revrev=546584
Log:
Adding a Maven2 pom.xml as per DBCP-211. I've removed a block of code from 
TestJOCLed that set the Xerces parser manually, I presume it was only there for 
odd situations in old JDKs. 

Added:
jakarta/commons/proper/dbcp/trunk/pom.xml   (with props)
Modified:

jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java

Added: jakarta/commons/proper/dbcp/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/pom.xml?view=autorev=546584
==
--- jakarta/commons/proper/dbcp/trunk/pom.xml (added)
+++ jakarta/commons/proper/dbcp/trunk/pom.xml Tue Jun 12 11:28:57 2007
@@ -0,0 +1,224 @@
+?xml version=1.0?
+!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You 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.
+--
+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
+groupIdorg.apache.commons/groupId
+artifactIdcommons-parent/artifactId
+version1/version
+  /parent
+  modelVersion4.0.0/modelVersion
+  groupIdcommons-dbcp/groupId
+  artifactIdcommons-dbcp/artifactId
+  version1.2.2/version
+  nameCommons DBCP/name
+
+  inceptionYear2001/inceptionYear
+  descriptionCommons Database Connection Pooling/description
+  urlhttp://jakarta.apache.org/commons/dbcp//url
+
+  issueManagement
+systemjira/system
+urlhttp://issues.apache.org/jira/browse/DBCP/url
+  /issueManagement
+
+  scm
+
connectionscm:svn:https://svn.apache.org/repos/asf/jakarta/commons/proper/dbcp/trunk/connection
+
developerConnectionscm:svn:https://svn.apache.org/repos/asf/jakarta/commons/proper/dbcp/trunk/developerConnection
+urlhttp://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/url
+  /scm
+
+  developers
+developer
+  nameMorgan Delagrange/name
+  idmorgand/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameGeir Magnusson/name
+  idgeirm/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameCraig McClanahan/name
+  idcraigmcc/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameJohn McNally/name
+  idjmcnally/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameMartin Poeschl/name
+  idmpoeschl/id
+  email[EMAIL PROTECTED]/email
+  organizationtucana.at/organization
+/developer
+developer
+  nameRodney Waldhoff/name
+  idrwaldhoff/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameDavid Weinrich/name
+  iddweinr1/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameDirk Verbeeck/name
+  iddirkv/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameYoav Shapira/name
+  idyoavs/id
+  email[EMAIL PROTECTED]/email
+  organizationApache Software Foundation/organization
+/developer
+developer
+  namePhil Steitz/name
+  idpsteitz/id
+  email/email
+  organization/organization
+/developer
+developer
+  nameJ#x00f6;rg Schaible/name
+  idjoehni/id
+  email[EMAIL PROTECTED]/email
+  organization/organization
+  timezone+1/timezone
+/developer
+  /developers
+  contributors
+contributor
+  nameTodd Carmichael/name
+  email[EMAIL PROTECTED]/email
+/contributor
+contributor
+  nameWayne Woodfield/name
+/contributor
+  /contributors
+
+  dependencies
+dependency
+  groupIdcommons-pool/groupId
+  artifactIdcommons-pool/artifactId
+  version1.3/version
+/dependency
+
+dependency
+  groupIdjunit/groupId
+  artifactIdjunit/artifactId
+  version3.8.1/version
+  scopetest/scope
+/dependency
+
+!-- tomcat naming jars for jndi reference tests --
+dependency
+  groupIdtomcat/groupId
+  artifactIdnaming

svn commit: r546591 - /jakarta/commons/proper/cli/tags/cli-1.1-RC1/

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 11:42:46 2007
New Revision: 546591

URL: http://svn.apache.org/viewvc?view=revrev=546591
Log:
Releasing RC1

Added:
jakarta/commons/proper/cli/tags/cli-1.1-RC1/
  - copied from r546590, jakarta/commons/proper/cli/branches/cli-1.0.x/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546593 - /jakarta/commons/proper/cli/tags/cli-1.1-RC1/

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 11:46:55 2007
New Revision: 546593

URL: http://svn.apache.org/viewvc?view=revrev=546593
Log:
Removing so I can change the release notes

Removed:
jakarta/commons/proper/cli/tags/cli-1.1-RC1/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546594 - /jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 11:54:32 2007
New Revision: 546594

URL: http://svn.apache.org/viewvc?view=revrev=546594
Log:
Adding information on lack of backwards compatibility to the release notes

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt?view=diffrev=546594r1=546593r2=546594
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/RELEASE-NOTES.txt Tue Jun 12 
11:54:32 2007
@@ -10,7 +10,18 @@
 This document contains the release notes for this version of the Commons
 CLI package. Commons CLI provides a simple API for working with the command 
line arguments and options.
 
-This is a bugfix release of CLI. 
+This is a bugfix release of CLI. Some parts are not backwards compatible:
+
+* The CommandLineParser interface has two additional methods. If you were 
extending this, 
+  then you will need to add methods to your classes. If you were extending the 
abstract 
+  Parser class, then you should be okay. 
+* The HelpFormatter class had publicly accessible fields. These are now 
accessed via 
+  get/set methods.
+* Two of HelpFormatter's methods no longer throw IllegalArgumentException.
+* The Option class is no longer cloneable, and no longer has an 
addValue(String) method.
+
+The best way to test any of the above is to recompile your code against CLI 
1.1. All 
+should result in compile time errors.
 
 For more information, read the documentation on the project site at 
 http://jakarta.apache.org/commons/cli/



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546597 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/conf/MANIFEST.MF

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 12:02:48 2007
New Revision: 546597

URL: http://svn.apache.org/viewvc?view=revrev=546597
Log:
Removing CLI2 parts from Manifest

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/src/conf/MANIFEST.MF

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/src/conf/MANIFEST.MF
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/conf/MANIFEST.MF?view=diffrev=546597r1=546596r2=546597
==
Binary files - no diff available.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546598 - /jakarta/commons/proper/cli/trunk/src/conf/MANIFEST.MF

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 12:03:06 2007
New Revision: 546598

URL: http://svn.apache.org/viewvc?view=revrev=546598
Log:
Removing CLI1 bits from manifest

Modified:
jakarta/commons/proper/cli/trunk/src/conf/MANIFEST.MF

Modified: jakarta/commons/proper/cli/trunk/src/conf/MANIFEST.MF
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/src/conf/MANIFEST.MF?view=diffrev=546598r1=546597r2=546598
==
Binary files - no diff available.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546604 - in /jakarta/commons/proper/cli/trunk/xdocs: index.xml navigation.xml upgrading-1.0-to-1.1.xml

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 12:16:17 2007
New Revision: 546604

URL: http://svn.apache.org/viewvc?view=revrev=546604
Log:
Improving release notes so they discuss the backwards compatibility issues

Added:
jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml   (with 
props)
Modified:
jakarta/commons/proper/cli/trunk/xdocs/index.xml
jakarta/commons/proper/cli/trunk/xdocs/navigation.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/index.xml?view=diffrev=546604r1=546603r2=546604
==
--- jakarta/commons/proper/cli/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/index.xml Tue Jun 12 12:16:17 2007
@@ -68,7 +68,7 @@
 p
 The latest version is v1.1. - 
 a 
href=http://jakarta.apache.org/site/downloads/downloads_commons-cli.cgi;Download
 now!/abr /
-The a href=changes-report.html#1_1release notes/a are also available.
+The a href=upgrading-1.0-to-1.1.htmlrelease notes/a are also available.
 /p
 p
 For previous releases, see the a 
href=http://archive.apache.org/dist/jakarta/commons/cli/;Apache Archive/a

Modified: jakarta/commons/proper/cli/trunk/xdocs/navigation.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/navigation.xml?view=diffrev=546604r1=546603r2=546604
==
--- jakarta/commons/proper/cli/trunk/xdocs/navigation.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/navigation.xml Tue Jun 12 12:16:17 
2007
@@ -36,6 +36,7 @@
   item name=Getting started  href=/introduction.html/
   item name=Usage scenarios   href=/usage.html/
   item name=Option properties href=/properties.html/
+  item name=Upgrading to 1.1 href=/upgrading-1.0-to-1.1.html/
   item name=Javadoc (1.1) href=api-release/index.html/
 /menu
 

Added: jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml?view=autorev=546604
==
--- jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml (added)
+++ jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml Tue Jun 12 
12:16:17 2007
@@ -0,0 +1,47 @@
+?xml version=1.0?
+!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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.
+--
+document
+ properties
+  titleUpgrading from 1.0 to 1.1/title
+  author email=commons-dev@jakarta.apache.orgCommons Documentation 
Team/author
+ /properties
+body
+!-- == --
+section name=Upgrading from 1.0 to 1.1
+  pCLI 1.1 is a bugfix release of CLI. The following changes were not 
backward compatible: /p
+
+  ul
+liThe CommandLineParser interface has two additional methods. If you 
were extending this,
+then you will need to add methods to your classes. If you were 
extending the abstract
+Parser class, then you should be okay. /li
+liThe HelpFormatter class had publicly accessible fields. These are now 
accessed via
+get/set methods. /li
+liTwo of HelpFormatter's methods no longer throw 
IllegalArgumentException. /li
+liThe Option class is no longer cloneable, and no longer has an 
addValue(String) method. /li
+  /ul
+
+  pThe best way to test any of the above is to recompile your code against 
CLI 1.1. All of the above 
+  should result in compile time errors. /p
+/section
+section name=Bugs fixed in 1.1
+  pThe list of bugs fixed in 1.1 may be seen via the 
+a href=changes-report.html#1_1changes report/a. /p
+/section
+!-- == --
+/body
+/document

Propchange: jakarta/commons/proper/cli/trunk/xdocs/upgrading-1.0-to-1.1.xml
--
svn:eol-style = native



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546619 - /jakarta/commons/proper/cli/tags/cli-1.1-RC1/

2007-06-12 Thread bayard
Author: bayard
Date: Tue Jun 12 13:01:24 2007
New Revision: 546619

URL: http://svn.apache.org/viewvc?view=revrev=546619
Log:
Tagging 1.1-rc1

Added:
jakarta/commons/proper/cli/tags/cli-1.1-RC1/
  - copied from r546618, jakarta/commons/proper/cli/branches/cli-1.0.x/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546321 - /jakarta/commons/trunks-proper/

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 16:58:19 2007
New Revision: 546321

URL: http://svn.apache.org/viewvc?view=revrev=546321
Log:
Removing the CLI avalon implementation from trunks-proper

Modified:
jakarta/commons/trunks-proper/   (props changed)

Propchange: jakarta/commons/trunks-proper/
--
--- svn:externals (original)
+++ svn:externals Mon Jun 11 16:58:19 2007
@@ -3,7 +3,6 @@
 betwixt https://svn.apache.org/repos/asf/jakarta/commons/proper/betwixt/trunk
 chain https://svn.apache.org/repos/asf/jakarta/commons/proper/chain/trunk
 cli https://svn.apache.org/repos/asf/jakarta/commons/proper/cli/trunk
-cli-avalon 
https://svn.apache.org/repos/asf/jakarta/commons/proper/cli/branches/avalon-implementation
 cli-1.0.x 
https://svn.apache.org/repos/asf/jakarta/commons/proper/cli/branches/cli-1.0.x
 codec https://svn.apache.org/repos/asf/jakarta/commons/proper/codec/trunk
 collections 
https://svn.apache.org/repos/asf/jakarta/commons/proper/collections/trunk



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546323 - /jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:22:59 2007
New Revision: 546323

URL: http://svn.apache.org/viewvc?view=revrev=546323
Log:
Fixing link to viewvc

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml?view=diffrev=546323r1=546322r2=546323
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/cvs-usage.xml Mon Jun 
11 17:22:59 2007
@@ -32,7 +32,7 @@
 /p
 p
   The best way to view the repository is via the
-  a 
href=http://svn.apache.org/viewcvs.cgi/jakarta/commons/proper/cli/trunk/;subversion
 viewer/a.
+  a 
href=http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/;subversion
 viewer/a.
 /p
 p
   The alternative is to use the



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546324 - /jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:23:38 2007
New Revision: 546324

URL: http://svn.apache.org/viewvc?view=revrev=546324
Log:
Fixing link to viewvc

Modified:
jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml?view=diffrev=546324r1=546323r2=546324
==
--- jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/cvs-usage.xml Mon Jun 11 17:23:38 
2007
@@ -33,7 +33,7 @@
 /p
 p
   The best way to view the repository is via the
-  a 
href=http://svn.apache.org/viewcvs.cgi/jakarta/commons/proper/cli/trunk/;subversion
 viewer/a.
+  a 
href=http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/;subversion
 viewer/a.
 /p
 p
   The alternative is to use the



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546325 - in /jakarta/commons/proper/cli/trunk/xdocs: changes.xml index.xml issue-tracking.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:28:17 2007
New Revision: 546325

URL: http://svn.apache.org/viewvc?view=revrev=546325
Log:
Updating the website. Instead of doing things in the xdocs on the 1.0 branch, 
I'm going to keep the 'one true xdoc' here in trunk and have it support both 
1.0 and 2.0

Added:
jakarta/commons/proper/cli/trunk/xdocs/changes.xml
Modified:
jakarta/commons/proper/cli/trunk/xdocs/index.xml
jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml

Added: jakarta/commons/proper/cli/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/changes.xml?view=autorev=546325
==
--- jakarta/commons/proper/cli/trunk/xdocs/changes.xml (added)
+++ jakarta/commons/proper/cli/trunk/xdocs/changes.xml Mon Jun 11 17:28:17 2007
@@ -0,0 +1,54 @@
+?xml version=1.0?
+!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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.
+--
+
+document
+  properties
+titleCommons CLI Release Notes/title
+  /properties
+  body
+release version=1.1 date=2007-?-?
+  description=This is a maintenance release containing bug fixes. 
+
+  action type=fix issue=CLI-51Parameter value -something 
misinterpreted as a parameter. /action
+  action type=fix issue=CLI-129CLI_1_BRANCH build.xml doesn't work. 
/action
+  action type=fix issue=CLI-59No Javadoc for HelpFormatter!. 
/action
+  action type=fix issue=CLI-29Options should not be able to be added 
more than once. /action
+  action type=fix issue=CLI-28Infinite Loop in Command-Line 
processing. /action
+  action type=fix issue=CLI-45Documentation errors. /action
+  action type=fix issue=CLI-71A weakness of parser. /action
+  action type=fix issue=CLI-13CommandLine.getOptionValue() behaves 
contrary to docs. /action
+  action type=fix issue=CLI-5Dependecy on commons-lang-2.0 but 
commons-lang-1.0 is obtained. /action
+  action type=fix issue=CLI-44Document enhancement. /action
+  action type=fix issue=CLI-69Error parsing option arguments. 
/action
+  action type=fix issue=CLI-38HelpFormatter doesn't function 
correctly for options with only LongOpt. /action
+  action type=fix issue=CLI-8Line separator as first char for 
helpformatter (footer) throws exception. /action
+  action type=fix issue=CLI-67Missing arguments in 
HelpFormatter.renderOptions(..). /action
+  action type=fix issue=CLI-26Only long options without short option 
seems to be noticed. /action
+  action type=fix issue=CLI-65Parser breaks up command line parms 
into single characters. /action
+  action type=fix issue=CLI-23Passing properties in Parser does not 
work for options with a single argument. /action
+  action type=fix issue=CLI-2Wrong usage summary. /action
+  action type=fix issue=CLI-21clone method in Option should use 
super.clone(). /action
+  action type=fix issue=CLI-56clone() method doesn't fully clone 
contents. /action
+  action type=fix issue=CLI-35HelpFormatter doesn't sort options 
properly. /action
+  action type=fix issue=CLI-130Remove the Commons Lang dependency. 
/action
+  action type=add issue=CLI-78Setting description of a Option. 
/action
+
+/release   
+
+  /body
+/document

Modified: jakarta/commons/proper/cli/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/index.xml?view=diffrev=546325r1=546324r2=546325
==
--- jakarta/commons/proper/cli/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/index.xml Mon Jun 11 17:28:17 2007
@@ -43,21 +43,21 @@
 The JavaDoc API documents are available online:
 /p
 ul
-liThe a href=api-release/index.htmlcurrent release 1.0/a/li
-!--liThe a href=api-n/index.htmlprevious version n/a/li--
-liThe a href=apidocs/index.htmllatest SVN/a/li
+liThe a href=api-release/index.htmlcurrent release 1.1/a/li
+liThe a href=api-1.0/index.htmlprevious version 1.0/a/li
+liThe a href=apidocs/index.htmllatest SVN (2.0-SNAPSHOT)/a/li
 /ul
 p
 The a href=cvs-usage.htmlsubversion repository/a can be
-a 
href=http://svn.apache.org/viewcvs.cgi/jakarta/commons/proper/cli

svn commit: r546327 - /jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:31:39 2007
New Revision: 546327

URL: http://svn.apache.org/viewvc?view=revrev=546327
Log:
Removing xdocs from the cli-1.0 side of things. The website lives in trunk. 

Removed:
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546329 - in /jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2: commandline/Parser.java option/ArgumentImpl.java validation/DateValidator.java

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:32:30 2007
New Revision: 546329

URL: http://svn.apache.org/viewvc?view=revrev=546329
Log:
Removing three unused imports (Parser/ArgumentImpl), and a pointless iteration 
through a list in DateValidator

Modified:

jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/commandline/Parser.java

jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/option/ArgumentImpl.java

jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java

Modified: 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/commandline/Parser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/commandline/Parser.java?view=diffrev=546329r1=546328r2=546329
==
--- 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/commandline/Parser.java
 (original)
+++ 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/commandline/Parser.java
 Mon Jun 11 17:32:30 2007
@@ -16,8 +16,6 @@
  */
 package org.apache.commons.cli2.commandline;
 
-import java.io.IOException;
-
 import java.util.LinkedList;
 import java.util.List;
 import java.util.ListIterator;

Modified: 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/option/ArgumentImpl.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/option/ArgumentImpl.java?view=diffrev=546329r1=546328r2=546329
==
--- 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/option/ArgumentImpl.java
 (original)
+++ 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/option/ArgumentImpl.java
 Mon Jun 11 17:32:30 2007
@@ -16,10 +16,8 @@
  */
 package org.apache.commons.cli2.option;
 
-import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Comparator;
-import java.util.Iterator;
 import java.util.List;
 import java.util.ListIterator;
 import java.util.Set;

Modified: 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java?view=diffrev=546329r1=546328r2=546329
==
--- 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
 (original)
+++ 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
 Mon Jun 11 17:32:30 2007
@@ -101,10 +101,6 @@
  *a List of DateFormats which dates must conform to
  */
 public DateValidator(final List formats) {
-for (Iterator iter = formats.iterator(); iter.hasNext();) {
-DateFormat format = (DateFormat) iter.next();
-}
-
 setFormats(formats);
 }
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546332 - /jakarta/commons/proper/cli/trunk/project.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:37:28 2007
New Revision: 546332

URL: http://svn.apache.org/viewvc?view=revrev=546332
Log:
Tighter list of projects, though I imagine we'll move to m2 asap

Modified:
jakarta/commons/proper/cli/trunk/project.xml

Modified: jakarta/commons/proper/cli/trunk/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/project.xml?view=diffrev=546332r1=546331r2=546332
==
--- jakarta/commons/proper/cli/trunk/project.xml (original)
+++ jakarta/commons/proper/cli/trunk/project.xml Mon Jun 11 17:37:28 2007
@@ -194,23 +194,15 @@
   /build
 
   reports
-!--reportmaven-developer-activity-plugin/report--
-!--reportmaven-file-activity-plugin/report--
-!--reportmaven-changelog-plugin/report--
-!--reportmaven-changes-plugin/report--
+reportmaven-changes-plugin/report
 reportmaven-jdepend-plugin/report
-reportmaven-checkstyle-plugin/report
+!--reportmaven-checkstyle-plugin/report--
 reportmaven-javadoc-plugin/report
 reportmaven-jdepend-plugin/report
 reportmaven-junit-report-plugin/report
 reportmaven-jxr-plugin/report
 reportmaven-license-plugin/report
-reportmaven-tasklist-plugin/report
 reportmaven-pmd-plugin/report
-!--reportmaven-simian-plugin/report
-reportmaven-faq-plugin/report
-reportmaven-jcoverage-plugin/report--
-!--reportmaven-tasks-plugin/report--
 !--reportmaven-findbugs-plugin/report--
   /reports
 /project



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546335 - /jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:46:20 2007
New Revision: 546335

URL: http://svn.apache.org/viewvc?view=revrev=546335
Log:
Updating 'maven ant'

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml?view=diffrev=546335r1=546334r2=546335
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml Mon Jun 11 17:46:20 
2007
@@ -1,32 +1,44 @@
 ?xml version=1.0 encoding=UTF-8?
 
 !--build.xml generated by maven from project.xml version 1.1-SNAPSHOT
-  on date May 28 2007, time 0053--
+  on date June 11 2007, time 1738--
 
 project default=jar name=commons-cli basedir=.
-  property name=defaulttargetdir value=target
+  !--Load local and user build preferences--
+
+  property file=build.properties
+  /property
+  property file=${user.home}/build.properties
   /property
-  property name=libdir value=target/lib
+  !--Build properties--
+
+  property name=defaulttargetdir value=${basedir}/target
   /property
-  property name=classesdir value=target/classes
+  property name=libdir value=${user.home}/.maven/repository
   /property
-  property name=testclassesdir value=target/test-classes
+  property name=classesdir value=${basedir}/target/classes
   /property
-  property name=testclassesdir value=target/test-classes
+  property name=testclassesdir value=${basedir}/target/test-classes
   /property
-  property name=testreportdir value=target/test-reports
+  property name=testreportdir value=${basedir}/target/test-reports
   /property
-  property name=distdir value=dist
+  property name=distdir value=${basedir}/dist
   /property
-  property name=javadocdir value=dist/docs/api
+  property name=javadocdir value=${basedir}/dist/docs/api
   /property
   property name=final.name value=commons-cli-1.1-SNAPSHOT
   /property
+  property name=proxy.host value=
+  /property
+  property name=proxy.port value=
+  /property
+  property name=proxy.username value=
+  /property
+  property name=proxy.password value=
+  /property
   path id=build.classpath
-fileset dir=${libdir}
-  include name=**/*.jar
-  /include
-/fileset
+pathelement location=${libdir}/junit/jars/junit-3.8.1.jar
+/pathelement
   /path
   target name=init description=o Initializes some properties
 mkdir dir=${libdir}
@@ -39,13 +51,25 @@
 
 available property=Junit.present classname=junit.framework.Test
 /available
+!--Test if user defined a proxy--
+
+condition property=useProxy
+  and
+isset property=proxy.host
+/isset
+not
+  equals trim=true arg2= arg1=${proxy.host}
+  /equals
+/not
+  /and
+/condition
   /target
   target name=compile description=o Compile the code depends=get-deps
 mkdir dir=${classesdir}
 /mkdir
 javac destdir=${classesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=src/java
+pathelement location=${basedir}/src/java
 /pathelement
   /src
   classpath refid=build.classpath
@@ -79,7 +103,7 @@
   target name=internal-test if=Junit.present 
depends=junit-present,compile-tests
 mkdir dir=${testreportdir}
 /mkdir
-junit dir=./ failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
+junit dir=${basedir} failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
   sysproperty key=basedir value=.
   /sysproperty
   formatter type=xml
@@ -95,9 +119,7 @@
 /pathelement
   /classpath
   batchtest todir=${testreportdir}
-fileset dir=src/test
-  include name=**/Test*.java
-  /include
+fileset dir=${basedir}/src/test
   include name=**/*Test.java
   /include
 /fileset
@@ -114,7 +136,7 @@
 /mkdir
 javac destdir=${testclassesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=src/test
+pathelement location=${basedir}/src/test
 /pathelement
   /src
   classpath
@@ -136,20 +158,39 @@
 /property
 property name=title value=CLI 1.1-SNAPSHOT API
 /property
-javadoc use=true private=true destdir=${javadocdir} author=true 
version=true sourcepath=src/java packagenames=org.apache.commons.*
+javadoc use=true private=true destdir=${javadocdir} author=true 
version=true sourcepath=${basedir}/src/java 
packagenames=org.apache.commons.*
   classpath
 path refid=build.classpath
 /path
   /classpath
 /javadoc
   /target
-  target name=get-deps unless=noget depends=init
+  target name=get-dep-junit.jar description=o Download the dependency : 
junit.jar unless=junit.jar 
depends=init

svn commit: r546337 - in /jakarta/commons/proper/cli/branches/cli-1.0.x: CLI2Converter.java CLI2ConverterTest.java maven.xml project.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:50:34 2007
New Revision: 546337

URL: http://svn.apache.org/viewvc?view=revrev=546337
Log:
Updating license header

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2Converter.java
jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2ConverterTest.java
jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2Converter.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2Converter.java?view=diffrev=546337r1=546336r2=546337
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2Converter.java (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2Converter.java Mon Jun 11 
17:50:34 2007
@@ -1,9 +1,10 @@
 /**
- * Copyright 2004 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
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
  *

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2ConverterTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2ConverterTest.java?view=diffrev=546337r1=546336r2=546337
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2ConverterTest.java 
(original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/CLI2ConverterTest.java Mon 
Jun 11 17:50:34 2007
@@ -1,9 +1,10 @@
 /**
- * Copyright 2004 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
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
  *

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml?view=diffrev=546337r1=546336r2=546337
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/maven.xml Mon Jun 11 17:50:34 
2007
@@ -1,9 +1,10 @@
 !--
-Copyright 2002-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
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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
 

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=546337r1=546336r2=546337
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon Jun 11 
17:50:34 2007
@@ -1,10 +1,11 @@
 ?xml version=1.0 encoding=UTF-8?
 !--
-   Copyright 2001-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
+   Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License

svn commit: r546339 - /jakarta/commons/proper/cli/trunk/project.properties

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:54:15 2007
New Revision: 546339

URL: http://svn.apache.org/viewvc?view=revrev=546339
Log:
Setting the JIRA format

Modified:
jakarta/commons/proper/cli/trunk/project.properties

Modified: jakarta/commons/proper/cli/trunk/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/project.properties?view=diffrev=546339r1=546338r2=546339
==
--- jakarta/commons/proper/cli/trunk/project.properties (original)
+++ jakarta/commons/proper/cli/trunk/project.properties Mon Jun 11 17:54:15 2007
@@ -5,6 +5,8 @@
 
 maven.changelog.factory=org.apache.maven.svnlib.SvnChangeLogFactory
 
+maven.changes.issue.template=http://issues.apache.org/jira/browse/%ISSUE%
+
 compile.debug = on
 compile.optimize = off
 compile.deprecation = off



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546340 - /jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 17:55:11 2007
New Revision: 546340

URL: http://svn.apache.org/viewvc?view=revrev=546340
Log:
Removing unused import

Modified:

jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java

Modified: 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java?view=diffrev=546340r1=546339r2=546340
==
--- 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
 (original)
+++ 
jakarta/commons/proper/cli/trunk/src/java/org/apache/commons/cli2/validation/DateValidator.java
 Mon Jun 11 17:55:11 2007
@@ -20,7 +20,6 @@
 import java.text.ParsePosition;
 
 import java.util.Date;
-import java.util.Iterator;
 import java.util.List;
 import java.util.ListIterator;
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546343 - /jakarta/commons/proper/cli/trunk/project.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 18:01:42 2007
New Revision: 546343

URL: http://svn.apache.org/viewvc?view=revrev=546343
Log:
Adding Brian Egge to the list of contributors

Modified:
jakarta/commons/proper/cli/trunk/project.xml

Modified: jakarta/commons/proper/cli/trunk/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/project.xml?view=diffrev=546343r1=546342r2=546343
==
--- jakarta/commons/proper/cli/trunk/project.xml (original)
+++ jakarta/commons/proper/cli/trunk/project.xml Mon Jun 11 18:01:42 2007
@@ -115,6 +115,12 @@
   /roles
 /contributor
 contributor
+  nameBrian Egge/name
+  roles
+rolemade the 1.1 release happen/role
+  /roles
+/contributor
+contributor
   nameBerin Loritsch/name
   email[EMAIL PROTECTED]/email
   roles



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r546345 - in /jakarta/commons/proper/cli/trunk/xdocs: building.xml examples/cp.xml examples/cvs.xml examples/index.xml examples/ls.xml index.xml navigation.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 18:25:02 2007
New Revision: 546345

URL: http://svn.apache.org/viewvc?view=revrev=546345
Log:
Updating site. Bringing some of the 2.0 content in; removing the stubbed out 
2.0 examples; updating the nav and adding the all important '1.x vs 2.x?' 
section to the front page

Removed:
jakarta/commons/proper/cli/trunk/xdocs/building.xml
jakarta/commons/proper/cli/trunk/xdocs/examples/cp.xml
jakarta/commons/proper/cli/trunk/xdocs/examples/cvs.xml
jakarta/commons/proper/cli/trunk/xdocs/examples/ls.xml
Modified:
jakarta/commons/proper/cli/trunk/xdocs/examples/index.xml
jakarta/commons/proper/cli/trunk/xdocs/index.xml
jakarta/commons/proper/cli/trunk/xdocs/navigation.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/examples/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/examples/index.xml?view=diffrev=546345r1=546344r2=546345
==
--- jakarta/commons/proper/cli/trunk/xdocs/examples/index.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/examples/index.xml Mon Jun 11 
18:25:02 2007
@@ -39,5 +39,11 @@
 found on the code[EMAIL PROTECTED]/code mailing list.
   /p
 /section
+
+section name=Examples
+  ul
+lia href=ant.htmlant/a/li
+  /ul
+/section
   /body
 /document

Modified: jakarta/commons/proper/cli/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/index.xml?view=diffrev=546345r1=546344r2=546345
==
--- jakarta/commons/proper/cli/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/index.xml Mon Jun 11 18:25:02 2007
@@ -29,8 +29,19 @@
 section name=Commons CLI
 p
 The Jakarta Commons CLI library provides an API for processing command line 
interfaces.
-It was formed by the merger of ideas and code from three different libraries -
-Werken, Avalon and Optz. 
+/p
+/section
+!-- == --
+section name=1.x vs 2.x?
+p
+Commons CLI 1.0 was formed from the merger of ideas and code from three 
different libraries -
+Werken, Avalon and Optz. In dealing with the bugs and the feature requests a 
freshly designed and not backwards compatible 
+CLI 2.0 was created, but never finished or released. Since then a CLI 1.1 
bugfix release has been made.
+/p
+p
+There are currently no plans to continue the 1.x line beyond bugfixes. The 2.x 
design is generally preferred and is in use, 
+however there is no current activity to make a 2.0 release. To this end, the 
1.1 release is recommended to most users 
+while the 2.x line is recommended for anyone interested in helping to get this 
better API released. 
 /p
 /section
 !-- == --

Modified: jakarta/commons/proper/cli/trunk/xdocs/navigation.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/navigation.xml?view=diffrev=546345r1=546344r2=546345
==
--- jakarta/commons/proper/cli/trunk/xdocs/navigation.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/navigation.xml Mon Jun 11 18:25:02 
2007
@@ -27,44 +27,26 @@
 
 menu name=Commons CLI
   item name=Overview href=/index.html/
-  item name=Download 
href=http://jakarta.apache.org/site/downloads/downloads_commons-cli.cgi/
-  item name=Javadoc (1.0 release) href=api-release/index.html/
+  item name=Download (1.1) 
href=http://jakarta.apache.org/site/downloads/downloads_commons-cli.cgi/
+  item name=SVN repository 
href=http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk//
+  item name=Mailing lists href=/mail-lists.html/
 /menu
 
-menu name=User guide
-  item name=Getting started   href=/introduction.html/
-  item name=Usage scenarios   href=/usage.html/
-  item name=Option properties href=/properties.html/
-/menu
-!--
-menu name=CLI1
-  item name=Overview  href=/introduction.html/
+menu name=CLI1 user guide
+  item name=Getting started  href=/introduction.html/
   item name=Usage scenarios   href=/usage.html/
   item name=Option properties href=/properties.html/
+  item name=Javadoc (1.1) href=api-release/index.html/
 /menu
-menu name=CLI2
+
+menu name=CLI2-dev user guide
   item name=Overview  href=/manual/index.html/
+  item name=Examples  href=/examples/index.html/
   item name=Options   href=/manual/options.html/
-  item name=Builders  href=/manual/builders.html/
-  item name=CommandLines  href=/manual/commandlines.html/
+  !--item name=Builders  href=/manual/builders.html/--
+  !--item name=CommandLines  href=/manual/commandlines.html/--
   item name=Validatorshref=/manual

svn commit: r546382 - in /jakarta/commons/proper/cli/branches/cli-1.0.x: build.xml project.xml

2007-06-11 Thread bayard
Author: bayard
Date: Mon Jun 11 22:23:16 2007
New Revision: 546382

URL: http://svn.apache.org/viewvc?view=revrev=546382
Log:
Preparing for 1.1 rc by changing 1.1-snapshot to 1.1

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml?view=diffrev=546382r1=546381r2=546382
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml Mon Jun 11 22:23:16 
2007
@@ -1,44 +1,32 @@
 ?xml version=1.0 encoding=UTF-8?
 
-!--build.xml generated by maven from project.xml version 1.1-SNAPSHOT
-  on date June 11 2007, time 1738--
+!--build.xml generated by maven from project.xml version 1.1
+  on date June 11 2007, time 2220--
 
 project default=jar name=commons-cli basedir=.
-  !--Load local and user build preferences--
-
-  property file=build.properties
-  /property
-  property file=${user.home}/build.properties
-  /property
-  !--Build properties--
-
-  property name=defaulttargetdir value=${basedir}/target
-  /property
-  property name=libdir value=${user.home}/.maven/repository
+  property name=defaulttargetdir value=target
   /property
-  property name=classesdir value=${basedir}/target/classes
+  property name=libdir value=target/lib
   /property
-  property name=testclassesdir value=${basedir}/target/test-classes
+  property name=classesdir value=target/classes
   /property
-  property name=testreportdir value=${basedir}/target/test-reports
+  property name=testclassesdir value=target/test-classes
   /property
-  property name=distdir value=${basedir}/dist
+  property name=testclassesdir value=target/test-classes
   /property
-  property name=javadocdir value=${basedir}/dist/docs/api
+  property name=testreportdir value=target/test-reports
   /property
-  property name=final.name value=commons-cli-1.1-SNAPSHOT
+  property name=distdir value=dist
   /property
-  property name=proxy.host value=
+  property name=javadocdir value=dist/docs/api
   /property
-  property name=proxy.port value=
-  /property
-  property name=proxy.username value=
-  /property
-  property name=proxy.password value=
+  property name=final.name value=commons-cli-1.1
   /property
   path id=build.classpath
-pathelement location=${libdir}/junit/jars/junit-3.8.1.jar
-/pathelement
+fileset dir=${libdir}
+  include name=**/*.jar
+  /include
+/fileset
   /path
   target name=init description=o Initializes some properties
 mkdir dir=${libdir}
@@ -51,25 +39,13 @@
 
 available property=Junit.present classname=junit.framework.Test
 /available
-!--Test if user defined a proxy--
-
-condition property=useProxy
-  and
-isset property=proxy.host
-/isset
-not
-  equals trim=true arg2= arg1=${proxy.host}
-  /equals
-/not
-  /and
-/condition
   /target
   target name=compile description=o Compile the code depends=get-deps
 mkdir dir=${classesdir}
 /mkdir
 javac destdir=${classesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=${basedir}/src/java
+pathelement location=src/java
 /pathelement
   /src
   classpath refid=build.classpath
@@ -103,7 +79,7 @@
   target name=internal-test if=Junit.present 
depends=junit-present,compile-tests
 mkdir dir=${testreportdir}
 /mkdir
-junit dir=${basedir} failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
+junit dir=./ failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
   sysproperty key=basedir value=.
   /sysproperty
   formatter type=xml
@@ -119,7 +95,7 @@
 /pathelement
   /classpath
   batchtest todir=${testreportdir}
-fileset dir=${basedir}/src/test
+fileset dir=src/test
   include name=**/*Test.java
   /include
 /fileset
@@ -136,7 +112,7 @@
 /mkdir
 javac destdir=${testclassesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=${basedir}/src/test
+pathelement location=src/test
 /pathelement
   /src
   classpath
@@ -154,43 +130,24 @@
   format pattern=2002- property=year
   /format
 /tstamp
-property name=copyright value=Copyright amp;copy;  Apache Software 
Foundation. All Rights Reserved.
+property name=copyright value=Copyright amp;copy; 2002-2007 Apache 
Software Foundation. All Rights Reserved.
 /property
-property name=title value=CLI 1.1-SNAPSHOT API
+property name=title value=CLI 1.1 API
 /property
-javadoc use=true private=true destdir=${javadocdir} author=true

svn commit: r545359 - /jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java

2007-06-07 Thread bayard
Author: bayard
Date: Thu Jun  7 18:15:35 2007
New Revision: 545359

URL: http://svn.apache.org/viewvc?view=revrev=545359
Log:
Fixing JXPATH-87 by storing the xmlURL

Modified:

jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java

Modified: 
jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java?view=diffrev=545359r1=545358r2=545359
==
--- 
jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java
 (original)
+++ 
jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/XMLDocumentContainer.java
 Thu Jun  7 18:15:35 2007
@@ -53,6 +53,7 @@
  * (resourceName) to load XML from a resource file.
  */
 public XMLDocumentContainer(URL xmlURL) {
+this.xmlURL = xmlURL;
 delegate = new DocumentContainer(xmlURL);
 }
 
@@ -100,4 +101,4 @@
 public void setValue(Object value) {
 throw new UnsupportedOperationException();
 }
-}
\ No newline at end of file
+}



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544744 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/Util.java test/org/apache/commons/cli/UtilTest.java test/org/apache/commons/cli/bug/BugCLI133Te

2007-06-06 Thread bayard
Author: bayard
Date: Wed Jun  6 00:10:30 2007
New Revision: 544744

URL: http://svn.apache.org/viewvc?view=revrev=544744
Log:
Applying the patches from Brian Egge in CLI-133

Added:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java
   (with props)

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI133Test.java
   (with props)
Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java?view=diffrev=544744r1=544743r2=544744
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java
 Wed Jun  6 00:10:30 2007
@@ -33,6 +33,9 @@
  */
 static String stripLeadingHyphens(String str)
 {
+if (str == null) {
+return null;
+}
 if (str.startsWith(--))
 {
 return str.substring(2, str.length());

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java?view=autorev=544744
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java
 (added)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java
 Wed Jun  6 00:10:30 2007
@@ -0,0 +1,30 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.commons.cli;
+
+import junit.framework.TestCase;
+
+/**
+ * @author brianegge
+ */
+public class UtilTest extends TestCase {
+public void testStripLeadingHyphens() {
+assertEquals(f, Util.stripLeadingHyphens(-f));
+assertEquals(foo, Util.stripLeadingHyphens(--foo));
+assertNull(Util.stripLeadingHyphens(null));
+}
+}

Propchange: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/UtilTest.java
--
svn:eol-style = native

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI133Test.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI133Test.java?view=autorev=544744
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI133Test.java
 (added)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI133Test.java
 Wed Jun  6 00:10:30 2007
@@ -0,0 +1,34 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.commons.cli.bug;
+
+import junit.framework.TestCase;
+import org.apache.commons.cli.*;
+
+/**
+ * @author brianegge
+ */
+public class BugCLI133Test extends TestCase {
+public void testOrder() throws ParseException {
+Option optionA = new

svn commit: r544762 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/HelpFormatter.java test/org/apache/commons/cli/BugsTest.java test/org/apache/commons/cli/TestHe

2007-06-06 Thread bayard
Author: bayard
Date: Wed Jun  6 01:01:19 2007
New Revision: 544762

URL: http://svn.apache.org/viewvc?view=revrev=544762
Log:
Applying Brian Egge's enhancement from CLI-131

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java?view=diffrev=544762r1=544761r2=544762
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java
 Wed Jun  6 01:01:19 2007
@@ -442,8 +442,10 @@
 // temp variable
 Option option;
 
+List optList = new ArrayList(options.getOptions());
+Collections.sort(optList, new OptionComparator());
 // iterate over the options
-for (Iterator i = options.getOptions().iterator(); i.hasNext();)
+for (Iterator i = optList.iterator(); i.hasNext();)
 {
 // get the next Option
 option = (Option) i.next();
@@ -503,8 +505,10 @@
 buff.append([);
 }
 
+List optList = new ArrayList(group.getOptions());
+Collections.sort(optList, new OptionComparator());
 // for each option in the OptionGroup
-for (Iterator i = group.getOptions().iterator(); i.hasNext();)
+for (Iterator i = optList.iterator(); i.hasNext();)
 {
 // whether the option is required or not is handled at group level
 appendOption(buff, (Option) i.next(), true);

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java?view=diffrev=544762r1=544761r2=544762
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java
 Wed Jun  6 01:01:19 2007
@@ -466,8 +466,8 @@
 StringWriter out = new StringWriter();
 formatter.printHelp(new 
PrintWriter(out),80,commandline,header,mOptions,2,2,footer,true);
 assertEquals(
-usage: commandline [--config arg] [-r arg] [-a arg] 
[-h] [-t] [-n] [-l+EOL+
-   arg] [-s arg] [-v]+EOL+
+usage: commandline [-a arg] [--config arg] [-h] [-l 
arg] [-n] [-r arg] + EOL +
+   [-s arg] [-t] [-v] + EOL +
 header+EOL+
   -a,--age arg  Age (in days) of cache item before 
being recomputed+EOL+
  --config arg   Use the specified configuration 
file+EOL+
@@ -527,7 +527,7 @@
 StringWriter out = new StringWriter();
 formatter.printHelp(new PrintWriter(out),80, foobar, , options, 2, 
2, , true);
 assertEquals(
-usage: foobar [-a] [-c] [--bbb]+SEP+
+usage: foobar [-a] [--bbb] [-c]+SEP+
   -a,--aaa  aaa+SEP+
  --bbb  bbb+SEP+
   -cccc+SEP

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java?view=diffrev=544762r1=544761r2=544762
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java
 Wed Jun  6 01:01:19 2007
@@ -27,9 +27,13 @@
  *
  * @author Slawek Zachcial
  * @author John Keyes ( john at integralsource.com )
+ * @author brianegge
  **/
 public class TestHelpFormatter extends TestCase
 {
+
+   private static final String EOL = System.getProperty(line.separator);
+
public static void main( String[] args )
{
   String[] testName = { TestHelpFormatter.class.getName() };
@@ -174,4 +178,23 @@
assertEquals(simple auto usage, expected, out.toString().trim());
out.reset();
}
+
+// This test ensures the options are properly sorted
+// See https://issues.apache.org/jira/browse/CLI-131
+public void

svn commit: r544763 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli: HelpFormatterTest.java TestHelpFormatter.java

2007-06-06 Thread bayard
Author: bayard
Date: Wed Jun  6 01:02:57 2007
New Revision: 544763

URL: http://svn.apache.org/viewvc?view=revrev=544763
Log:
Renaming TestHelpFormatter to the more obvious HelpFormatterTest

Added:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterTest.java
   (with props)
Removed:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterTest.java?view=autorev=544763
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterTest.java
 (added)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterTest.java
 Wed Jun  6 01:02:57 2007
@@ -0,0 +1,200 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.commons.cli;
+
+import java.io.ByteArrayOutputStream;
+import java.io.PrintWriter;
+
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+/** 
+ * Test case for the HelpFormatter class 
+ *
+ * @author Slawek Zachcial
+ * @author John Keyes ( john at integralsource.com )
+ * @author brianegge
+ **/
+public class HelpFormatterTest extends TestCase
+{
+
+   private static final String EOL = System.getProperty(line.separator);
+
+   public static void main( String[] args )
+   {
+  String[] testName = { HelpFormatterTest.class.getName() };
+  junit.textui.TestRunner.main(testName);
+   }
+
+   public static TestSuite suite()
+   {
+  return new TestSuite(HelpFormatterTest.class);
+   }
+
+   public HelpFormatterTest( String s )
+   {
+  super( s );
+   }
+
+   public void testFindWrapPos()
+  throws Exception
+   {
+  HelpFormatter hf = new HelpFormatter();
+
+  String text = This is a test.;
+  //text width should be max 8; the wrap postition is 7
+  assertEquals(wrap position, 7, hf.findWrapPos(text, 8, 0));
+  //starting from 8 must give -1 - the wrap pos is after end
+  assertEquals(wrap position 2, -1, hf.findWrapPos(text, 8, 8));
+  //if there is no a good position before width to make a wrapping look 
for the next one
+  text =  aa;
+  assertEquals(wrap position 3, 4, hf.findWrapPos(text, 3, 0));
+   }
+
+   public void testPrintWrapped()
+  throws Exception
+   {
+  StringBuffer sb = new StringBuffer();
+  HelpFormatter hf = new HelpFormatter();
+
+  String text = This is a test.;
+  String expected;
+
+  expected = This is a + hf.getNewLine() + test.;
+  hf.renderWrappedText(sb, 12, 0, text);
+  assertEquals(single line text, expected, sb.toString());
+
+  sb.setLength(0);
+  expected = This is a + hf.getNewLine() + test.;
+  hf.renderWrappedText(sb, 12, 4, text);
+  assertEquals(single line padded text, expected, sb.toString());
+
+  text =
+    + hf.getNewLine() +
+ aa + hf.getNewLine() +
+ a;
+
+  expected = text;
+  sb.setLength(0);
+  hf.renderWrappedText(sb, 16, 0, text);
+  assertEquals(multi line text, expected, sb.toString());
+
+  expected =
+    + hf.getNewLine() +
+ aa + hf.getNewLine() +
+ a;
+  sb.setLength(0);
+  hf.renderWrappedText(sb, 16, 4, text);
+  assertEquals(multi-line padded text, expected, sb.toString());
+   }
+
+   public void testPrintOptions()
+   throws Exception
+   {
+   StringBuffer sb = new StringBuffer();
+   HelpFormatter hf = new HelpFormatter();
+   final int leftPad = 1;
+   final int descPad = 3;
+   final String lpad = hf.createPadding(leftPad);
+   final String dpad = hf.createPadding(descPad);
+   Options options = null;
+   String expected = null;
+
+   options = new Options().addOption(a, false,     
);
+   expected = lpad + -a + dpad +     ;
+   hf.renderOptions(sb, 60

svn commit: r544764 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-06-06 Thread bayard
Author: bayard
Date: Wed Jun  6 01:03:17 2007
New Revision: 544764

URL: http://svn.apache.org/viewvc?view=revrev=544764
Log:
Test* is not necessary anymore

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=544764r1=544763r2=544764
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Wed Jun  6 
01:03:17 2007
@@ -167,7 +167,6 @@
 !-- Unit test classes --
 unitTest
   includes
-include**/Test*.java/include
 include**/*Test.java/include
   /includes
 /unitTest



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544360 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/Parser.java test/org/apache/commons/cli/OptionsTest.java

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:01:08 2007
New Revision: 544360

URL: http://svn.apache.org/viewvc?view=revrev=544360
Log:
Applying Brian Egge's improvement from CLI-132

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java?view=diffrev=544360r1=544359r2=544360
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 Mon Jun  4 21:01:08 2007
@@ -295,7 +295,10 @@
 if (requiredOptions.size()  0)
 {
 Iterator iter = requiredOptions.iterator();
-StringBuffer buff = new StringBuffer();
+StringBuffer buff = new StringBuffer(Missing required option);
+buff.append(requiredOptions.size() == 1 ?  : s);
+buff.append(: );
+
 
 // loop through the required options
 while (iter.hasNext())

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java?view=diffrev=544360r1=544359r2=544360
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java
 Mon Jun  4 21:01:08 2007
@@ -94,7 +94,28 @@
 assertTrue(Everything in help should be in 
all,allOptions.containsAll(helpOptions));
 }
 
+public void testMissingOptionException() throws ParseException {
+Options options = new Options();
+options.addOption(OptionBuilder.isRequired().create(f));
+try {
+new PosixParser().parse(options, new String[0]);
+fail(Expected MissingOptionException to be thrown);
+} catch (MissingOptionException e) {
+assertEquals(Missing required option: f, e.getMessage());
+}
+}
 
+public void testMissingOptionsException() throws ParseException {
+Options options = new Options();
+options.addOption(OptionBuilder.isRequired().create(f));
+options.addOption(OptionBuilder.isRequired().create(x));
+try {
+new PosixParser().parse(options, new String[0]);
+fail(Expected MissingOptionException to be thrown);
+} catch (MissingOptionException e) {
+assertEquals(Missing required options: fx, e.getMessage());
+}
+}
 
 }
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544363 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs: index.xml issue-tracking.xml

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:11:30 2007
New Revision: 544363

URL: http://svn.apache.org/viewvc?view=revrev=544363
Log:
Switching the website from Bugzilla to JIRA

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/issue-tracking.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml?view=diffrev=544363r1=544362r2=544363
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml Mon Jun  4 
21:11:30 2007
@@ -70,9 +70,7 @@
 so prefix your email by [cli].
 /p
 p
-Issues may be reported via a href=issue-tracking.htmlASF Bugzilla/a.
-Please remember that Bugzilla is shared between all commons components,
-so prefix your issue by [cli].
+Issues may be reported via the a href=issue-tracking.htmlASF JIRA/a.
 /p
 /section
 !-- == --

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/issue-tracking.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/issue-tracking.xml?view=diffrev=544363r1=544362r2=544363
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/issue-tracking.xml 
(original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/issue-tracking.xml Mon 
Jun  4 21:11:30 2007
@@ -1,17 +1,18 @@
 ?xml version=1.0?
 !--
-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
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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 iouage governing permissions and
+See the License for the specific language governing permissions and
 limitations under the License.
 --
 document
@@ -23,20 +24,25 @@
 !-- == --
 section name=Issue tracking
 p
-  Commons CLI uses a href=http://issues.apache.org/bugzilla/;ASF 
Bugzilla/a for tracking issues.
-  To use Bugzilla you may need to a 
href=http://issues.apache.org/bugzilla/createaccount.cgi;create an 
account/a.
+  Commons CLI uses the a href=http://issues.apache.org/jira/browse/CLI;ASF 
JIRA/a for tracking issues.
+/p
+p
+  To use JIRA you may need to a 
href=http://issues.apache.org/jira/secure/Signup!default.jspa;create an 
account/a
+  (if you have previously created/updated Commons issues using Bugzilla an 
account will have been automatically
+  created and you can use the a 
href=http://issues.apache.org/jira/secure/ForgotPassword!default.jspa;Forgot 
Password/a
+  page to get a new password).
 /p
 p
   If you would like to report a bug, or raise an enhancement request with
   Commons CLI please do the following:
   ol
-  lia 
href=http://issues.apache.org/bugzilla/buglist.cgi?bug_status=UNCONFIRMEDamp;bug_status=NEWamp;bug_status=ASSIGNEDamp;bug_status=REOPENEDamp;bug_status=NEEDINFOamp;product=Commonsamp;component=CLI;Search
 existing open bugs/a.
+  lia 
href=http://issues.apache.org/jira/secure/IssueNavigator.jspa?reset=trueamp;pid=12310463amp;sorter/field=issuekeyamp;sorter/order=DESCamp;status=1amp;status=4;Search
 existing open bugs/a.
   If you find your issue listed then please add a comment with your 
details./li
   lia 
href=http://mail-archives.apache.org/mod_mbox/jakarta-commons-dev/;Search the 
mailing list archive/a.
   You may find your issue or idea has already been discussed./li
-  lia 
href=http://issues.apache.org/bugzilla/enter_bug.cgi?product=Commonsamp;component=CLIamp;version=1.0%20Finalamp;short_desc=%5Bcli%5D%20%22Your%20subject%20heading%20here%22amp;comment=Please%20provide%20details%20here.%20Its%20best%20to%20submit%20patches%20that%20alter%0D%0Aexisting%20file%20content%20in%20%22unified%20diff%22%20format.%20%0D%0A%0D%0ASubmissions%20that%20provide%20new%20files%20can%20be%20supplied%20as%20direct%20file%0D%0Aattachments%20or%20archives%20in%20zip%20or%20tar.gz%20format.%20please%20be%20kind%20%0D%0Aenough%20to%20identify%20the%20format%20of%20the

svn commit: r544364 - in /jakarta/commons/proper/cli/trunk/xdocs: index.xml issue-tracking.xml

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:12:11 2007
New Revision: 544364

URL: http://svn.apache.org/viewvc?view=revrev=544364
Log:
the ASF JIRA, rather than ASF JIRA

Modified:
jakarta/commons/proper/cli/trunk/xdocs/index.xml
jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml

Modified: jakarta/commons/proper/cli/trunk/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/index.xml?view=diffrev=544364r1=544363r2=544364
==
--- jakarta/commons/proper/cli/trunk/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/index.xml Mon Jun  4 21:12:11 2007
@@ -73,7 +73,7 @@
 so prefix your email by [cli].
 /p
 p
-Issues may be reported via a href=issue-tracking.htmlASF JIRA/a.
+Issues may be reported via the a href=issue-tracking.htmlASF JIRA/a.
 /p
 /section
 !-- == --

Modified: jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml?view=diffrev=544364r1=544363r2=544364
==
--- jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml (original)
+++ jakarta/commons/proper/cli/trunk/xdocs/issue-tracking.xml Mon Jun  4 
21:12:11 2007
@@ -24,7 +24,7 @@
 !-- == --
 section name=Issue tracking
 p
-  Commons CLI uses a href=http://issues.apache.org/jira/;ASF JIRA/a for 
tracking issues.
+  Commons CLI uses the a href=http://issues.apache.org/jira/;ASF JIRA/a 
for tracking issues.
   To use JIRA you may need to a 
href=https://issues.apache.org/jira/secure/Signup!default.jspa;create an 
account/a.
 /p
 p



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544369 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:27:38 2007
New Revision: 544369

URL: http://svn.apache.org/viewvc?view=revrev=544369
Log:
Added Brian's name to the list of contributors

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=544369r1=544368r2=544369
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon Jun  4 
21:27:38 2007
@@ -114,6 +114,12 @@
   /roles
 /contributor
 contributor
+  nameBrian Egge/name
+  roles
+rolemade the 1.1 release happen/role
+  /roles
+/contributor
+contributor
   nameBerin Loritsch/name
   email[EMAIL PROTECTED]/email
   roles



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544375 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:42:44 2007
New Revision: 544375

URL: http://svn.apache.org/viewvc?view=revrev=544375
Log:
Also adding Andrew Shirley

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=544375r1=544374r2=544375
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon Jun  4 
21:42:44 2007
@@ -134,6 +134,12 @@
 rolesupplied patch/role
   /roles
 /contributor
+contributor
+  nameAndrew Shirley/name
+  roles
+rolelots of fixes for 1.1 and 2.0/role
+  /roles
+/contributor
   /contributors
 
   dependencies



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r544377 - /jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml

2007-06-04 Thread bayard
Author: bayard
Date: Mon Jun  4 21:44:56 2007
New Revision: 544377

URL: http://svn.apache.org/viewvc?view=revrev=544377
Log:
Use the changes-report for the release notes

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml?view=diffrev=544377r1=544376r2=544377
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/index.xml Mon Jun  4 
21:44:56 2007
@@ -40,7 +40,7 @@
 The JavaDoc API documents are available online:
 /p
 ul
-liThe a href=api-release/index.htmlcurrent release 1.0/a/li
+liThe a href=api-release/index.htmlcurrent release 1.1/a/li
 !--liThe a href=api-n/index.htmlprevious version n/a/li--
 liThe a href=apidocs/index.htmllatest SVN/a/li
 /ul
@@ -52,9 +52,9 @@
 !-- == --
 section name=Releases
 p
-The latest version is v1.0. - 
+The latest version is v1.1. - 
 a 
href=http://jakarta.apache.org/site/downloads/downloads_commons-cli.cgi;Download
 now!/abr /
-The a href=release_1_0.htmlrelease notes/a are also available.
+The a href=changes-report.html#1_1release notes/a are also available.
 /p
 p
 For previous releases, see the a 
href=http://archive.apache.org/dist/jakarta/commons/cli/;Apache Archive/a
@@ -73,79 +73,7 @@
 Issues may be reported via the a href=issue-tracking.htmlASF JIRA/a.
 /p
 /section
-!-- == --
 
-!--  p
-CLI1 was formed by the merger of ideas and code from three different
-libraries and allows most simple interfaces to be modelled.  CLI1
-became increasingly difficult to maintain and develop further and so
-CLI2 has been developed with the goals of clearer responsibilities and
-being more flexible.  The intention is that CLI2 should be able to
-model a far greater selection of interfaces and do so more completely,
-validating as much as possible.
-  /p
-  p
-The redesigned CLI2 is rooted in the 
codeorg.apache.commons.cli2/code
-package and the distribution retains the 
codeorg.apache.commons.cli/code
-package so that the upgrade doesn't break old code.  The CLI1 package
-should be regarded as deprecated to encourage the transition to the
-more flexible CLI2 framework but minor bug fixes and patches may be
-accepted to ensure that CLI1 based applications continue to function as
-expected.
-  /p
-  p
-The rest of the documentation is split into the following three 
sections:
-ul
-  lia href=manual/index.htmlCLI2/a - a reference manual for 
version 2/li
-  lia href=introduction.htmlCLI1/a - documentation for version 
1 /li
-  lia href=examples/index.htmlExamples/a - a selection of 
worked examples demonstrating CLI2 features/li
-/ul
-  /p
-  p
-The latest version of this documentation is available on the web:
-ul
-  lia 
href=http://jakarta.apache.org/commons/cli/;http://jakarta.apache.org/commons/cli//a/li
-  li
-a 
href=http://jakarta.apache.org/commons/cli/commons-cli.pdf;http://jakarta.apache.org/commons/cli/commons-cli.pdf/a
 
-a 
href=http://jakarta.apache.org/commons/cli/commons-cli.pdf;img border=0 
src=images/pdf.gif//a 
-  /li
-/ul
-  /p
-/section
-section name=Dependancies
-  p
-The generated list of a href=dependencies.htmldependencies/a 
-lists the libraries needed to compile and test Commons CLI.  To use 
-the precompiled distribution none of these dependancies are strictly 
-necessary.  The following is a breakdown of what is required and when:
-  /p
-  table
-tr
-  thLibrary/ththUsage/th
-/tr
-tr
-  tdJava 1.2/td
-  tdThis is the minimum java level needed to use CLI2/td
-/tr
-tr
-  tdJava 1.4/td
-  tdNeeded if the PreferencesCommandLine is needed/td
-/tr
-tr
-  tdcommons-lang/td
-  tdNeeded if the CLI1 package is being used/td
-/tr
-tr
-  tdjdepend/td
-  tdNeeded to build and test CLI2 only/td
-/tr
-tr
-  tdjunit/td
-  tdNeeded to build and test CLI1 and CLI2/td
-/tr
-  /table
-/section
---
   /body
 
 /document



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542140 - in /jakarta/commons/proper/cli/branches/cli-1.0.x: project.xml src/java/org/apache/commons/cli/PatternOptionBuilder.java src/java/org/apache/commons/cli/TypeHandler.java src/test

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 00:54:52 2007
New Revision: 542140

URL: http://svn.apache.org/viewvc?view=revrev=542140
Log:
Removing the Commons Lang dependency. This removes certain obscure number 
formats as being parseable by the PatternOptionBuilder, but I suspect they 
don't matter. 

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=542140r1=542139r2=542140
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon May 28 
00:54:52 2007
@@ -132,13 +132,6 @@
 
   dependencies
 
-!-- used in TypeHandler --
-dependency
-  groupIdcommons-lang/groupId
-  artifactIdcommons-lang/artifactId
-  version2.1/version
-/dependency
-
 !-- used for unit tests --
 dependency
   groupIdjunit/groupId

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java?view=diffrev=542140r1=542139r2=542140
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
 Mon May 28 00:54:52 2007
@@ -27,7 +27,7 @@
  * trtdb@/tdtd-b [classname]/td/tr
  * trtdcgt;/tdtd-c [filename]/td/tr
  * trtdd+/tdtd-d [classname] (creates object via empty 
contructor)/td/tr
- * trtde%/tdtd-e [number] (creates Number instance)/td/tr
+ * trtde%/tdtd-e [number] (creates Double/Long instance depeding on 
existing of a '.')/td/tr
  * trtdf//tdtd-f [url]/td/tr
  * trtdg:/tdtd-g [string]/td/tr
  * /table

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java?view=diffrev=542140r1=542139r2=542140
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
 Mon May 28 00:54:52 2007
@@ -22,8 +22,6 @@
 
 import java.util.Date;
 
-import org.apache.commons.lang.math.NumberUtils;
-
 /**
   * This is a temporary implementation. TypeHandler will handle the 
   * pluggableness of OptionTypes and it will direct all of these types 
@@ -149,7 +147,8 @@
 }
 
 /**
- * pCreate a number from a String./p
+ * pCreate a number from a String. If a . is present, it creates a 
+ *Double, otherwise a Long. /p
  *
  * @param str the value
  * @return the number represented by codestr/code, if codestr/code
@@ -157,18 +156,26 @@
  */
 public static Number createNumber(String str)
 {
-// Needs to be able to create
 try
 {
-// do searching for decimal point etc, but atm just make an Integer
-return NumberUtils.createNumber(str);
+if( str != null )
+{
+if( str.indexOf('.') != -1 )
+{
+return Double.valueOf(str);
+}
+else
+{
+return Long.valueOf(str);
+}
+}
 }
 catch (NumberFormatException nfe)
 {
 System.err.println(nfe.getMessage());
-
-return null;
 }
+
+return null;
 }
 
 /**
@@ -254,4 +261,4 @@
 //return FileW.findFiles(str);
 return null;
 }
-}
\ No newline at end of file
+}

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java?view=diffrev=542140r1=542139r2=542140
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 (original

svn commit: r542141 - /jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 00:55:03 2007
New Revision: 542141

URL: http://svn.apache.org/viewvc?view=revrev=542141
Log:
Regenerated build.xml from changed pom

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml?view=diffrev=542141r1=542140r2=542141
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml Mon May 28 00:55:03 
2007
@@ -1,46 +1,32 @@
 ?xml version=1.0 encoding=UTF-8?
 
 !--build.xml generated by maven from project.xml version 1.1-SNAPSHOT
-  on date May 14 2007, time 1658--
+  on date May 28 2007, time 0053--
 
 project default=jar name=commons-cli basedir=.
-  !--Load local and user build preferences--
-
-  property file=build.properties
-  /property
-  property file=${user.home}/build.properties
+  property name=defaulttargetdir value=target
   /property
-  !--Build properties--
-
-  property name=defaulttargetdir value=${basedir}/target
+  property name=libdir value=target/lib
   /property
-  property name=libdir value=${user.home}/.maven/repository
+  property name=classesdir value=target/classes
   /property
-  property name=classesdir value=${basedir}/target/classes
+  property name=testclassesdir value=target/test-classes
   /property
-  property name=testclassesdir value=${basedir}/target/test-classes
+  property name=testclassesdir value=target/test-classes
   /property
-  property name=testreportdir value=${basedir}/target/test-reports
+  property name=testreportdir value=target/test-reports
   /property
-  property name=distdir value=${basedir}/dist
+  property name=distdir value=dist
   /property
-  property name=javadocdir value=${basedir}/dist/docs/api
+  property name=javadocdir value=dist/docs/api
   /property
   property name=final.name value=commons-cli-1.1-SNAPSHOT
   /property
-  property name=proxy.host value=
-  /property
-  property name=proxy.port value=
-  /property
-  property name=proxy.username value=
-  /property
-  property name=proxy.password value=
-  /property
   path id=build.classpath
-pathelement location=${libdir}/commons-lang/jars/commons-lang-2.1.jar
-/pathelement
-pathelement location=${libdir}/junit/jars/junit-3.8.1.jar
-/pathelement
+fileset dir=${libdir}
+  include name=**/*.jar
+  /include
+/fileset
   /path
   target name=init description=o Initializes some properties
 mkdir dir=${libdir}
@@ -53,25 +39,13 @@
 
 available property=Junit.present classname=junit.framework.Test
 /available
-!--Test if user defined a proxy--
-
-condition property=useProxy
-  and
-isset property=proxy.host
-/isset
-not
-  equals trim=true arg2= arg1=${proxy.host}
-  /equals
-/not
-  /and
-/condition
   /target
   target name=compile description=o Compile the code depends=get-deps
 mkdir dir=${classesdir}
 /mkdir
 javac destdir=${classesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=${basedir}/src/java
+pathelement location=src/java
 /pathelement
   /src
   classpath refid=build.classpath
@@ -105,7 +79,7 @@
   target name=internal-test if=Junit.present 
depends=junit-present,compile-tests
 mkdir dir=${testreportdir}
 /mkdir
-junit dir=${basedir} failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
+junit dir=./ failureproperty=test.failure printSummary=yes 
fork=true haltonerror=true
   sysproperty key=basedir value=.
   /sysproperty
   formatter type=xml
@@ -121,7 +95,7 @@
 /pathelement
   /classpath
   batchtest todir=${testreportdir}
-fileset dir=${basedir}/src/test
+fileset dir=src/test
   include name=**/Test*.java
   /include
   include name=**/*Test.java
@@ -140,7 +114,7 @@
 /mkdir
 javac destdir=${testclassesdir} deprecation=true debug=true 
optimize=false excludes=**/package.html
   src
-pathelement location=${basedir}/src/test
+pathelement location=src/test
 /pathelement
   /src
   classpath
@@ -162,51 +136,20 @@
 /property
 property name=title value=CLI 1.1-SNAPSHOT API
 /property
-javadoc use=true private=true destdir=${javadocdir} author=true 
version=true sourcepath=${basedir}/src/java 
packagenames=org.apache.commons.*
+javadoc use=true private=true destdir=${javadocdir} author=true 
version=true sourcepath=src/java packagenames=org.apache.commons.*
   classpath
 path refid=build.classpath
 /path
   /classpath
 /javadoc
   /target
-  target name=get-dep-commons-lang.jar description=o Download the 
dependency : commons

svn commit: r542143 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 00:58:54 2007
New Revision: 542143

URL: http://svn.apache.org/viewvc?view=revrev=542143
Log:
Minor source refactoring

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java?view=diffrev=542143r1=542142r2=542143
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 Mon May 28 00:58:54 2007
@@ -26,22 +26,12 @@
 public class PatternOptionBuilderTest
 extends TestCase
 {
-public static void main( String[] args )
-   {
-  String[] testName = { PatternOptionBuilderTest.class.getName() };
-  junit.textui.TestRunner.main(testName);
-   }
 
public static TestSuite suite()
{
   return new TestSuite(PatternOptionBuilderTest.class);
}
 
-   public PatternOptionBuilderTest( String s )
-   {
-  super( s );
-   }
-
public void testSimplePattern()
{
try {
@@ -51,26 +41,27 @@
CommandLineParser parser = new PosixParser();
CommandLine line = parser.parse(options,args);
 
-   // tests the char methods of CommandLine that delegate to
-   // the String methods
assertEquals(flag a, foo, line.getOptionValue(a));
-   assertEquals(flag a, foo, line.getOptionValue('a'));
assertEquals(string flag a, foo, line.getOptionObject(a));
-   assertEquals(string flag a, foo, line.getOptionObject('a'));
assertEquals(object flag b, new java.util.Vector(), 
line.getOptionObject(b));
-   assertEquals(object flag b, new java.util.Vector(), 
line.getOptionObject('b'));
-   assertEquals(boolean true flag c, true, line.hasOption(c));
-   assertEquals(boolean true flag c, true, line.hasOption('c'));
-   assertEquals(boolean false flag d, false, line.hasOption(d));
-   assertEquals(boolean false flag d, false, line.hasOption('d'));
+   assertTrue(boolean true flag c, line.hasOption(c));
+   assertFalse(boolean false flag d, line.hasOption(d));
assertEquals(file flag e, new java.io.File(build.xml), 
line.getOptionObject(e));
-   assertEquals(file flag e, new java.io.File(build.xml), 
line.getOptionObject('e'));
assertEquals(class flag f, java.util.Calendar.class, 
line.getOptionObject(f));
-   assertEquals(class flag f, java.util.Calendar.class, 
line.getOptionObject('f'));
assertEquals(number flag n, new Double(4.5), 
line.getOptionObject(n));
-   assertEquals(number flag n, new Double(4.5), 
line.getOptionObject('n'));
assertEquals(url flag t, new 
java.net.URL(http://jakarta.apache.org/;), line.getOptionObject(t));
+
+   // tests the char methods of CommandLine that delegate to the 
String methods
+   assertEquals(flag a, foo, line.getOptionValue('a'));
+   assertEquals(string flag a, foo, line.getOptionObject('a'));
+   assertEquals(object flag b, new java.util.Vector(), 
line.getOptionObject('b'));
+   assertTrue(boolean true flag c, line.hasOption('c'));
+   assertFalse(boolean false flag d, line.hasOption('d'));
+   assertEquals(file flag e, new java.io.File(build.xml), 
line.getOptionObject('e'));
+   assertEquals(class flag f, java.util.Calendar.class, 
line.getOptionObject('f'));
+   assertEquals(number flag n, new Double(4.5), 
line.getOptionObject('n'));
assertEquals(url flag t, new 
java.net.URL(http://jakarta.apache.org/;), line.getOptionObject('t'));
+
/// DATES NOT SUPPORTED YET.
//  assertEquals(number flag t, new 
java.util.Date(1023400137276L), line.getOptionObject('z'));
// input is:  Thu Jun 06 17:48:57 EDT 2002



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542144 - in /jakarta/commons/proper/cli/branches/cli-1.0.x: ./ src/java/org/apache/commons/cli/ src/test/org/apache/commons/cli/ src/test/org/apache/commons/cli/bug/

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:01:25 2007
New Revision: 542144

URL: http://svn.apache.org/viewvc?view=revrev=542144
Log:
Fixing the copyright statements

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/NOTICE.txt

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/AlreadySelectedException.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/BasicParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLineParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/HelpFormatter.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/MissingArgumentException.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/MissingOptionException.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/OptionBuilder.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/OptionGroup.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/OptionValidator.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Options.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/ParseException.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/UnrecognizedOptionException.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Util.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ApplicationTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ArgumentIsOptionTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BugsTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/BuildTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/GnuParseTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/HelpFormatterExamples.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/LongOptionWithShort.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionBuilderTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionGroupTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionsTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseRequiredTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ParseTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/TestHelpFormatter.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValueTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/ValuesTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI18Test.java

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/NOTICE.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/NOTICE.txt?view=diffrev=542144r1=542143r2=542144
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/NOTICE.txt (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/NOTICE.txt Mon May 28 
01:01:25 2007
@@ -1,2 +1,5 @@
+Apache Jakarta Commons CLI
+Copyright 2001-2007 The Apache Software Foundation
+
 This product includes software developed by
 The Apache Software Foundation (http://www.apache.org/).

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/AlreadySelectedException.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/AlreadySelectedException.java?view=diffrev=542144r1=542143r2=542144

svn commit: r542145 - in /jakarta/commons/proper/cli: branches/avalon-implementation/project.properties branches/avalon-implementation/style.css branches/cli-1.0.x/project.properties branches/cli-1.0.

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:07:04 2007
New Revision: 542145

URL: http://svn.apache.org/viewvc?view=revrev=542145
Log:
Removing dead file

Removed:
jakarta/commons/proper/cli/branches/avalon-implementation/style.css
jakarta/commons/proper/cli/branches/cli-1.0.x/style.css
jakarta/commons/proper/cli/trunk/style.css
Modified:
jakarta/commons/proper/cli/branches/avalon-implementation/project.properties
jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties
jakarta/commons/proper/cli/trunk/project.properties

Modified: 
jakarta/commons/proper/cli/branches/avalon-implementation/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/avalon-implementation/project.properties?view=diffrev=542145r1=542144r2=542145
==
--- 
jakarta/commons/proper/cli/branches/avalon-implementation/project.properties 
(original)
+++ 
jakarta/commons/proper/cli/branches/avalon-implementation/project.properties 
Mon May 28 01:07:04 2007
@@ -22,7 +22,6 @@
 maven.xdoc.poweredby.image=maven-feather.png
 
 maven.javadoc.links=http://java.sun.com/j2se/1.4/docs/api/
-#maven.javadoc.stylesheet=${basedir}/style.css
 
 # Jar Manifest and Additional Attributes
 maven.jar.manifest=${basedir}/src/conf/MANIFEST.MF

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties?view=diffrev=542145r1=542144r2=542145
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties Mon May 28 
01:07:04 2007
@@ -24,7 +24,6 @@
 maven.xdoc.poweredby.image=maven-feather.png
 
 maven.javadoc.links=http://java.sun.com/j2se/1.4/docs/api/
-#maven.javadoc.stylesheet=${basedir}/style.css
 
 # Jar Manifest and Additional Attributes
 maven.jar.manifest=${basedir}/src/conf/MANIFEST.MF

Modified: jakarta/commons/proper/cli/trunk/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/trunk/project.properties?view=diffrev=542145r1=542144r2=542145
==
--- jakarta/commons/proper/cli/trunk/project.properties (original)
+++ jakarta/commons/proper/cli/trunk/project.properties Mon May 28 01:07:04 2007
@@ -24,7 +24,6 @@
 maven.xdoc.poweredby.image=maven-feather.png
 
 maven.javadoc.links=http://java.sun.com/j2se/1.4/docs/api/
-#maven.javadoc.stylesheet=${basedir}/style.css
 
 # Jar Manifest and Additional Attributes
 maven.jar.manifest=${basedir}/src/conf/MANIFEST.MF



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542146 - /jakarta/commons/proper/cli/branches/cli-1.0.x/doap_cli.rdf

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:08:01 2007
New Revision: 542146

URL: http://svn.apache.org/viewvc?view=revrev=542146
Log:
Not much point having a doap on the branch

Removed:
jakarta/commons/proper/cli/branches/cli-1.0.x/doap_cli.rdf


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542151 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli: GnuParser.java Option.java PosixParser.java TypeHandler.java

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:32:20 2007
New Revision: 542151

URL: http://svn.apache.org/viewvc?view=revrev=542151
Log:
Fixing Findbugs warnings and adding a bold WARNING to GnuParser that there is a 
large lump of non-executable code

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java?view=diffrev=542151r1=542150r2=542151
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/GnuParser.java
 Mon May 28 01:32:20 2007
@@ -106,6 +106,10 @@
 }
 else
 {
+// WARNING: Findbugs reports major problems with the 
following code. 
+//  As option cannot be null, currentOption cannot 
and 
+//  much of the code below is never going to be 
run.
+
 currentOption = option;
 
 // special option
@@ -169,6 +173,6 @@
 }
 }
 
-return (String[]) tokens.toArray(new String[] {  });
+return (String[]) tokens.toArray(new String[tokens.size()]);
 }
-}
\ No newline at end of file
+}

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=542151r1=542150r2=542151
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Mon May 28 01:32:20 2007
@@ -541,7 +541,7 @@
 public String[] getValues()
 {
 return hasNoValues()
-   ? null : (String[]) this.values.toArray(new String[] {  });
+   ? null : (String[]) this.values.toArray(new 
String[this.values.size()]);
 }
 
 /**

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java?view=diffrev=542151r1=542150r2=542151
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
 Mon May 28 01:32:20 2007
@@ -160,7 +160,7 @@
 gobble(iter);
 }
 
-return (String[]) tokens.toArray(new String[] {  });
+return (String[]) tokens.toArray(new String[tokens.size()]);
 }
 
 /**
@@ -308,4 +308,4 @@
 }
 }
 }
-}
\ No newline at end of file
+}

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java?view=diffrev=542151r1=542150r2=542151
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/TypeHandler.java
 Mon May 28 01:32:20 2007
@@ -208,14 +208,7 @@
  */
 public static Date createDate(String str)
 {
-Date date = null;
-
-if (date == null)
-{
-System.err.println(Unable to parse:  + str);
-}
-
-return date;
+throw new UnsupportedOperationException(Not yet implemented);
 }
 
 /**



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542152 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:37:06 2007
New Revision: 542152

URL: http://svn.apache.org/viewvc?view=revrev=542152
Log:
Updating the reports

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=542152r1=542151r2=542152
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon May 28 
01:37:06 2007
@@ -162,23 +162,20 @@
   /build
 
   reports
-!--reportmaven-developer-activity-plugin/report--
-!--reportmaven-file-activity-plugin/report--
-!--reportmaven-changelog-plugin/report--
-!--reportmaven-changes-plugin/report--
-reportmaven-jdepend-plugin/report
-reportmaven-checkstyle-plugin/report
+reportmaven-changes-plugin/report
+
+!-- Pointless given tht the code is most definitely not 'sun' style --
+!--reportmaven-checkstyle-plugin/report--  
+
 reportmaven-javadoc-plugin/report
-reportmaven-jdepend-plugin/report
 reportmaven-junit-report-plugin/report
 reportmaven-jxr-plugin/report
 reportmaven-license-plugin/report
-reportmaven-tasklist-plugin/report
 reportmaven-pmd-plugin/report
-!--reportmaven-simian-plugin/report
-reportmaven-faq-plugin/report
-reportmaven-jcoverage-plugin/report--
-!--reportmaven-tasks-plugin/report--
-!--reportmaven-findbugs-plugin/report--
+!--
+reportmaven-simian-plugin/report
+reportmaven-jcoverage-plugin/report
+reportmaven-findbugs-plugin/report
+--
   /reports
 /project



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542156 - /jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:48:14 2007
New Revision: 542156

URL: http://svn.apache.org/viewvc?view=revrev=542156
Log:
Bugs fixed in CLI 1.1

Added:
jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml   (with 
props)

Added: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml?view=autorev=542156
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml (added)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml Mon May 28 
01:48:14 2007
@@ -0,0 +1,54 @@
+?xml version=1.0?
+!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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.
+--
+
+document
+  properties
+titleCommons CLI Release Notes/title
+  /properties
+  body
+release version=1.1 date=2007-?-?
+  description=This is a maintenance release containing bug fixes. 
+
+  action type=fix issue=CLI-51Parameter value -something 
misinterpreted as a parameter. /action
+  action type=fix issue=CLI-129CLI_1_BRANCH build.xml doesn't work. 
/action
+  action type=fix issue=CLI-59No Javadoc for HelpFormatter!. 
/action
+  action type=fix issue=CLI-29Options should not be able to be added 
more than once. /action
+  action type=fix issue=CLI-28Infinite Loop in Command-Line 
processing. /action
+  action type=fix issue=CLI-45Documentation errors. /action
+  action type=fix issue=CLI-71A weakness of parser. /action
+  action type=fix issue=CLI-13CommandLine.getOptionValue() behaves 
contrary to docs. /action
+  action type=fix issue=CLI-5Dependecy on commons-lang-2.0 but 
commons-lang-1.0 is obtained. /action
+  action type=fix issue=CLI-44Document enhancement. /action
+  action type=fix issue=CLI-69Error parsing option arguments. 
/action
+  action type=fix issue=CLI-38HelpFormatter doesn't function 
correctly for options with only LongOpt. /action
+  action type=fix issue=CLI-8Line separator as first char for 
helpformatter (footer) throws exception. /action
+  action type=fix issue=CLI-67Missing arguments in 
HelpFormatter.renderOptions(..). /action
+  action type=fix issue=CLI-26Only long options without short option 
seems to be noticed. /action
+  action type=fix issue=CLI-65Parser breaks up command line parms 
into single characters. /action
+  action type=fix issue=CLI-23Passing properties in Parser does not 
work for options with a single argument. /action
+  action type=fix issue=CLI-2Wrong usage summary. /action
+  action type=fix issue=CLI-21clone method in Option should use 
super.clone(). /action
+  action type=fix issue=CLI-56clone() method doesn't fully clone 
contents. /action
+  action type=fix issue=CLI-35HelpFormatter doesn't sort options 
properly. /action
+  action type=fix issue=CLI-130Remove the Commons Lang dependency. 
/action
+  action type=add issue=CLI-78Setting description of a Option. 
/action
+
+/release   
+
+  /body
+/document

Propchange: jakarta/commons/proper/cli/branches/cli-1.0.x/xdocs/changes.xml
--
svn:eol-style = native



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r542160 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties

2007-05-28 Thread bayard
Author: bayard
Date: Mon May 28 01:52:24 2007
New Revision: 542160

URL: http://svn.apache.org/viewvc?view=revrev=542160
Log:
Fixing changes report links to JIRA

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties?view=diffrev=542160r1=542159r2=542160
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties Mon May 28 
01:52:24 2007
@@ -5,6 +5,8 @@
 
 maven.changelog.factory=org.apache.maven.svnlib.SvnChangeLogFactory
 
+maven.changes.issue.template=http://issues.apache.org/jira/browse/%ISSUE%
+
 compile.debug = on
 compile.optimize = off
 compile.deprecation = off



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541831 - /jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java

2007-05-25 Thread bayard
Author: bayard
Date: Fri May 25 17:52:24 2007
New Revision: 541831

URL: http://svn.apache.org/viewvc?view=revrev=541831
Log:
Adding javadoc for :

Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java?view=diffrev=541831r1=541830r2=541831
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PatternOptionBuilder.java
 Fri May 25 17:52:24 2007
@@ -29,6 +29,7 @@
  * trtdd+/tdtd-d [classname] (creates object via empty 
contructor)/td/tr
  * trtde%/tdtd-e [number] (creates Number instance)/td/tr
  * trtdf//tdtd-f [url]/td/tr
+ * trtdg:/tdtd-g [string]/td/tr
  * /table
  *
  * p



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541408 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/Option.java java/org/apache/commons/cli/Parser.java test/org/apache/commons/cli/OptionTest.java

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:07:06 2007
New Revision: 541408

URL: http://svn.apache.org/viewvc?view=revrev=541408
Log:
Applying Brian Egge and my work from CLI-71 to fix a lingering data problem in 
the parser and to confirm that other bugs have already been fixed

Added:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI71Test.java
Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java?view=diffrev=541408r1=541407r2=541408
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
 Thu May 24 13:07:06 2007
@@ -631,4 +631,15 @@
 return result;
 }
 
+/**
+ * pClear the Option values. After a 
+ * parse is complete, these are left with data in them 
+ * and they need clearing if another parse is done. /p
+ *
+ * See: a href=https://issues.apache.org/jira/browse/CLI-71;CLI-71/a
+ */
+void clearValues() {
+this.values.clear();
+}
+
 }

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java?view=diffrev=541408r1=541407r2=541408
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Parser.java
 Thu May 24 13:07:06 2007
@@ -132,6 +132,13 @@
 {
 // initialise members
 this.options = options;
+
+// clear out the data in options in case it's been used before (CLI-71)
+for (Iterator it = options.helpOptions().iterator(); it.hasNext();) {
+Option opt = (Option) it.next();
+opt.clearValues();
+}
+
 requiredOptions = options.getRequiredOptions();
 cmd = new CommandLine();
 
@@ -403,4 +410,4 @@
 // set the option on the command line
 cmd.addOption(opt);
 }
-}
\ No newline at end of file
+}

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java?view=autorev=541408
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 (added)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/OptionTest.java
 Thu May 24 13:07:06 2007
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.commons.cli;
+
+import junit.framework.TestCase;
+
+/**
+ * @author brianegge
+ */
+public class OptionTest extends TestCase {
+
+   public void testClear() {
+   Option option = new Option(x, true, );
+   assertEquals(0, option.getValuesList().size());
+   option.addValue(a);
+   assertEquals(1, option.getValuesList().size());
+   option.clearValues();
+   assertEquals(0, option.getValuesList().size());
+   }
+
+}

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI71Test.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI71Test.java?view=autorev=541408

svn commit: r541411 - /jakarta/commons/proper/cli/dead/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:15:34 2007
New Revision: 541411

URL: http://svn.apache.org/viewvc?view=revrev=541411
Log:
Deleting in svn is easy to undo, but impossible to find that something was 
deleted later on so it really is very, very final. Dumping stuff here instead

Added:
jakarta/commons/proper/cli/dead/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541412 - in /jakarta/commons/proper/cli: branches/commons-configuration-integration/ dead/commons-configuration-integration/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:16:05 2007
New Revision: 541412

URL: http://svn.apache.org/viewvc?view=revrev=541412
Log:
Dead branch

Added:
jakarta/commons/proper/cli/dead/commons-configuration-integration/
  - copied from r541411, 
jakarta/commons/proper/cli/branches/commons-configuration-integration/
Removed:
jakarta/commons/proper/cli/branches/commons-configuration-integration/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541414 - in /jakarta/commons/proper/cli: branches/RESEARCH_CLI_2_ROXSPRING/ dead/RESEARCH_CLI_2_ROXSPRING/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:16:38 2007
New Revision: 541414

URL: http://svn.apache.org/viewvc?view=revrev=541414
Log:
Dead branch

Added:
jakarta/commons/proper/cli/dead/RESEARCH_CLI_2_ROXSPRING/
  - copied from r541413, 
jakarta/commons/proper/cli/branches/RESEARCH_CLI_2_ROXSPRING/
Removed:
jakarta/commons/proper/cli/branches/RESEARCH_CLI_2_ROXSPRING/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541415 - in /jakarta/commons/proper/cli: branches/CLI_2_DEV_BRANCH/ dead/CLI_2_DEV_BRANCH/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:17:07 2007
New Revision: 541415

URL: http://svn.apache.org/viewvc?view=revrev=541415
Log:
Dead branch

Added:
jakarta/commons/proper/cli/dead/CLI_2_DEV_BRANCH/
  - copied from r541414, 
jakarta/commons/proper/cli/branches/CLI_2_DEV_BRANCH/
Removed:
jakarta/commons/proper/cli/branches/CLI_2_DEV_BRANCH/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541416 - in /jakarta/commons/proper/cli: branches/CLI_1_BRANCH/ dead/CLI_1_BRANCH/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:17:36 2007
New Revision: 541416

URL: http://svn.apache.org/viewvc?view=revrev=541416
Log:
Dead branch

Added:
jakarta/commons/proper/cli/dead/CLI_1_BRANCH/
  - copied from r541415, jakarta/commons/proper/cli/branches/CLI_1_BRANCH/
Removed:
jakarta/commons/proper/cli/branches/CLI_1_BRANCH/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541417 - in /jakarta/commons/proper/cli: branches/CLI_1_0_1_prepare/ dead/CLI_1_0_1_prepare/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:17:56 2007
New Revision: 541417

URL: http://svn.apache.org/viewvc?view=revrev=541417
Log:
Dead branch

Added:
jakarta/commons/proper/cli/dead/CLI_1_0_1_prepare/
  - copied from r541416, 
jakarta/commons/proper/cli/branches/CLI_1_0_1_prepare/
Removed:
jakarta/commons/proper/cli/branches/CLI_1_0_1_prepare/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r541418 - in /jakarta/commons/proper/cli: dead/Root_cli_1_x/ tags/Root_cli_1_x/

2007-05-24 Thread bayard
Author: bayard
Date: Thu May 24 13:18:28 2007
New Revision: 541418

URL: http://svn.apache.org/viewvc?view=revrev=541418
Log:
Dead tag

Added:
jakarta/commons/proper/cli/dead/Root_cli_1_x/
  - copied from r541417, jakarta/commons/proper/cli/tags/Root_cli_1_x/
Removed:
jakarta/commons/proper/cli/tags/Root_cli_1_x/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r540661 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/PosixParser.java test/org/apache/commons/cli/bug/BugCLI51Test.java

2007-05-22 Thread bayard
Author: bayard
Date: Tue May 22 10:47:16 2007
New Revision: 540661

URL: http://svn.apache.org/viewvc?view=revrev=540661
Log:
Applying test and fix patch from CLI-51. Thanks to Brian Egge. 

Added:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI51Test.java
Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java?view=diffrev=540661r1=540660r2=540661
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/PosixParser.java
 Tue May 22 10:47:16 2007
@@ -99,7 +99,7 @@
 
 // an iterator for the command line tokens
 Iterator iter = Arrays.asList(arguments).iterator();
-String token = null;
+String token;
 
 // process each command line token
 while (iter.hasNext())
@@ -302,7 +302,8 @@
 }
 else
 {
-tokens.add(- + ch);
+tokens.add(token);
+break;
 }
 }
 }

Added: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI51Test.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI51Test.java?view=autorev=540661
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI51Test.java
 (added)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI51Test.java
 Tue May 22 10:47:16 2007
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.commons.cli.bug;
+
+import junit.framework.TestCase;
+import org.apache.commons.cli.CommandLine;
+import org.apache.commons.cli.CommandLineParser;
+import org.apache.commons.cli.Options;
+import org.apache.commons.cli.ParseException;
+import org.apache.commons.cli.PosixParser;
+import org.apache.commons.cli.OptionBuilder;
+import org.apache.commons.cli.Option;
+
+/**
+ * @author brianegge
+ */
+public class BugCLI51Test
+extends TestCase
+{
+public void test() throws Exception
+{
+Options options = buildCommandLineOptions();
+CommandLineParser parser = new PosixParser();
+String[] args = new String[] {-t, -something };
+CommandLine commandLine;
+commandLine = parser.parse( options, args );
+assertEquals(-something, commandLine.getOptionValue( 't'));
+}
+
+private Options buildCommandLineOptions()
+{
+Option opt = OptionBuilder.withArgName( t).hasArg().create('t');
+Options options = new Options();
+options.addOption( opt);
+return options;
+}
+}



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r539632 - in /jakarta/commons/proper/io/trunk/src: java/org/apache/commons/io/EndianUtils.java test/org/apache/commons/io/EndianUtilsTest.java

2007-05-18 Thread bayard
Author: bayard
Date: Fri May 18 16:37:59 2007
New Revision: 539632

URL: http://svn.apache.org/viewvc?view=revrev=539632
Log:
Applying Hiroshi's test from IO-117 with my fix. Fixes negative number 
possibilities in EndianUtils.readSwappedUnsignedInteger()

Modified:

jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/EndianUtils.java

jakarta/commons/proper/io/trunk/src/test/org/apache/commons/io/EndianUtilsTest.java

Modified: 
jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/EndianUtils.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/EndianUtils.java?view=diffrev=539632r1=539631r2=539632
==
--- 
jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/EndianUtils.java 
(original)
+++ 
jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/EndianUtils.java 
Fri May 18 16:37:59 2007
@@ -182,10 +182,13 @@
  * @return the value read
  */
 public static long readSwappedUnsignedInteger(byte[] data, int offset) {
-return ( ( ( data[ offset + 0 ]  0xff )  0 ) +
-( ( data[ offset + 1 ]  0xff )  8 ) +
-( ( data[ offset + 2 ]  0xff )  16 ) +
-( ( data[ offset + 3 ]  0xff )  24 ) );
+long low = ( ( ( data[ offset + 0 ]  0xff )  0 ) +
+ ( ( data[ offset + 1 ]  0xff )  8 ) +
+ ( ( data[ offset + 2 ]  0xff )  16 ) );
+
+long high = data[ offset + 3 ]  0xff;
+
+return (high  24) + (0xL  low); 
 }
 
 /**
@@ -368,10 +371,13 @@
 int value3 = read( input );
 int value4 = read( input );
 
-return ( ( value1  0xff )  0 ) +
-( ( value2  0xff )  8 ) +
-( ( value3  0xff )  16 ) +
-( ( value4  0xff )  24 );
+long low = ( ( ( value1  0xff )  0 ) +
+ ( ( value2  0xff )  8 ) +
+ ( ( value3  0xff )  16 ) );
+
+long high = value4  0xff;
+
+return (high  24) + (0xL  low); 
 }
 
 /**

Modified: 
jakarta/commons/proper/io/trunk/src/test/org/apache/commons/io/EndianUtilsTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/trunk/src/test/org/apache/commons/io/EndianUtilsTest.java?view=diffrev=539632r1=539631r2=539632
==
--- 
jakarta/commons/proper/io/trunk/src/test/org/apache/commons/io/EndianUtilsTest.java
 (original)
+++ 
jakarta/commons/proper/io/trunk/src/test/org/apache/commons/io/EndianUtilsTest.java
 Fri May 18 16:37:59 2007
@@ -263,4 +263,17 @@
 }
 }
 
+// tests #IO-117
+public void testUnsignedOverrun() throws Exception {
+byte[] target = new byte[] { 0, 0, 0, (byte)0x80 };
+long expected = 0x8000L;
+
+long actual = EndianUtils.readSwappedUnsignedInteger(target, 0);
+assertEquals(readSwappedUnsignedInteger(byte[], int) was incorrect, 
expected, actual);
+
+ByteArrayInputStream in = new ByteArrayInputStream(target);
+actual = EndianUtils.readSwappedUnsignedInteger(in);
+assertEquals(readSwappedUnsignedInteger(InputStream) was incorrect, 
expected, actual);
+}
+
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r539638 - in /jakarta/commons/proper/io/branches/b1_3/src: java/org/apache/commons/io/EndianUtils.java test/org/apache/commons/io/EndianUtilsTest.java

2007-05-18 Thread bayard
Author: bayard
Date: Fri May 18 16:44:30 2007
New Revision: 539638

URL: http://svn.apache.org/viewvc?view=revrev=539638
Log:
Applying Hiroshi's test from IO-117 with my fix. Fixes negative number 
possibilities in EndianUtils.readSwappedUnsignedInteger()

Modified:

jakarta/commons/proper/io/branches/b1_3/src/java/org/apache/commons/io/EndianUtils.java

jakarta/commons/proper/io/branches/b1_3/src/test/org/apache/commons/io/EndianUtilsTest.java

Modified: 
jakarta/commons/proper/io/branches/b1_3/src/java/org/apache/commons/io/EndianUtils.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/branches/b1_3/src/java/org/apache/commons/io/EndianUtils.java?view=diffrev=539638r1=539637r2=539638
==
--- 
jakarta/commons/proper/io/branches/b1_3/src/java/org/apache/commons/io/EndianUtils.java
 (original)
+++ 
jakarta/commons/proper/io/branches/b1_3/src/java/org/apache/commons/io/EndianUtils.java
 Fri May 18 16:44:30 2007
@@ -182,10 +182,13 @@
  * @return the value read
  */
 public static long readSwappedUnsignedInteger(byte[] data, int offset) {
-return ( ( ( data[ offset + 0 ]  0xff )  0 ) +
-( ( data[ offset + 1 ]  0xff )  8 ) +
-( ( data[ offset + 2 ]  0xff )  16 ) +
-( ( data[ offset + 3 ]  0xff )  24 ) );
+long low = ( ( ( data[ offset + 0 ]  0xff )  0 ) +
+ ( ( data[ offset + 1 ]  0xff )  8 ) +
+ ( ( data[ offset + 2 ]  0xff )  16 ) );
+
+long high = data[ offset + 3 ]  0xff;
+
+return (high  24) + (0xL  low); 
 }
 
 /**
@@ -368,10 +371,13 @@
 int value3 = read( input );
 int value4 = read( input );
 
-return ( ( value1  0xff )  0 ) +
-( ( value2  0xff )  8 ) +
-( ( value3  0xff )  16 ) +
-( ( value4  0xff )  24 );
+long low = ( ( ( value1  0xff )  0 ) +
+ ( ( value2  0xff )  8 ) +
+ ( ( value3  0xff )  16 ) );
+
+long high = value4  0xff;
+
+return (high  24) + (0xL  low); 
 }
 
 /**

Modified: 
jakarta/commons/proper/io/branches/b1_3/src/test/org/apache/commons/io/EndianUtilsTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/branches/b1_3/src/test/org/apache/commons/io/EndianUtilsTest.java?view=diffrev=539638r1=539637r2=539638
==
--- 
jakarta/commons/proper/io/branches/b1_3/src/test/org/apache/commons/io/EndianUtilsTest.java
 (original)
+++ 
jakarta/commons/proper/io/branches/b1_3/src/test/org/apache/commons/io/EndianUtilsTest.java
 Fri May 18 16:44:30 2007
@@ -263,4 +263,17 @@
 }
 }
 
+// tests #IO-117
+public void testUnsignedOverrun() throws Exception {
+byte[] target = new byte[] { 0, 0, 0, (byte)0x80 };
+long expected = 0x8000L;
+
+long actual = EndianUtils.readSwappedUnsignedInteger(target, 0);
+assertEquals(readSwappedUnsignedInteger(byte[], int) was incorrect, 
expected, actual);
+
+ByteArrayInputStream in = new ByteArrayInputStream(target);
+actual = EndianUtils.readSwappedUnsignedInteger(in);
+assertEquals(readSwappedUnsignedInteger(InputStream) was incorrect, 
expected, actual);
+}
+
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r539650 - /jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt

2007-05-18 Thread bayard
Author: bayard
Date: Fri May 18 17:45:35 2007
New Revision: 539650

URL: http://svn.apache.org/viewvc?view=revrev=539650
Log:
Updating release notes with IO-117 fix

Modified:
jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt

Modified: jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt?view=diffrev=539650r1=539649r2=539650
==
--- jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/io/branches/b1_3/RELEASE-NOTES.txt Fri May 18 
17:45:35 2007
@@ -48,7 +48,9 @@
 
 - Some tests, which are implicitly assuming a Unix-like file system, are
   now skipped on Windows. [IO-115]
-
+- EndianUtils
+  - Both readSwappedUnsignedInteger(...) methods could return negative 
+numbers due to int/long casting. [IO-117]
 
 
 Bug fixes from 1.3



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r539651 - /jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt

2007-05-18 Thread bayard
Author: bayard
Date: Fri May 18 17:46:29 2007
New Revision: 539651

URL: http://svn.apache.org/viewvc?view=revrev=539651
Log:
Moving release notes to 1.4. 

Modified:
jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt

Modified: jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt?view=diffrev=539651r1=539650r2=539651
==
--- jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/io/trunk/RELEASE-NOTES.txt Fri May 18 17:46:29 2007
@@ -1,7 +1,7 @@
 $Id$
 
 Commons IO Package
-   Version 1.3.1
+   Version 1.4
   Release Notes
 
 
@@ -15,23 +15,17 @@
 and endian transformation classes.
 
 
-Compatibility with 1.3
---
-Binary compatible - No
-  See [IO-113]
+Compatibility with 1.3.2
+
+Binary compatible - ?
 
-Source compatible - No
-  See [IO-113]
+Source compatible - ?
 
-Semantic compatible - Yes
+Semantic compatible - ?
 
 
-Bug fixes from 1.3
---
-
-- FileUtils
-  - NPE in openOutputStream(File) when file has no parent in path [IO-112]
-  - readFileToString(File) is not static [IO-113]
+Bug fixes from 1.3.2
+
 
 Feedback
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r538020 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 16:55:17 2007
New Revision: 538020

URL: http://svn.apache.org/viewvc?view=revrev=538020
Log:
jdepend not used by cli-1, so removing that from the pom. Also fixing the 
comment for the lang dep

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=538020r1=538019r2=538020
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon May 14 
16:55:17 2007
@@ -132,7 +132,7 @@
 
   dependencies
 
-!-- used in PatternOptionBuilder --
+!-- used in TypeHandler --
 dependency
   groupIdcommons-lang/groupId
   artifactIdcommons-lang/artifactId
@@ -144,19 +144,6 @@
   groupIdjunit/groupId
   artifactIdjunit/artifactId
   version3.8.1/version
-  properties
-   scopetest/scope
-   comment
-Required only for testing.
-   /comment
-  /properties
-/dependency
-
-!-- used for unit tests --
-dependency
-  groupIdjdepend/groupId
-  artifactIdjdepend/artifactId
-  version2.5/version
   properties
scopetest/scope
comment



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r538021 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 16:56:01 2007
New Revision: 538021

URL: http://svn.apache.org/viewvc?view=revrev=538021
Log:
Fixing the location of the maven central repo

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties?view=diffrev=538021r1=538020r2=538021
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.properties Mon May 14 
16:56:01 2007
@@ -1,6 +1,8 @@
 # ---
 # P R O J E C T  P R O P E R T I E S
 # ---
+maven.repo.remote=http://repo1.maven.org/maven
+
 maven.changelog.factory=org.apache.maven.svnlib.SvnChangeLogFactory
 
 compile.debug = on



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r538023 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 16:57:18 2007
New Revision: 538023

URL: http://svn.apache.org/viewvc?view=revrev=538023
Log:
Fixing groupId to retain legacy groupId

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=538023r1=538022r2=538023
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon May 14 
16:57:18 2007
@@ -15,7 +15,7 @@
limitations under the License.
 --
 project
-  groupIdorg.apache.commons/groupId
+  groupIdcommons-cli/groupId
   artifactIdcommons-cli/artifactId
   nameCLI/name
   currentVersion2.0-SNAPSHOT/currentVersion



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r538024 - /jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 17:00:44 2007
New Revision: 538024

URL: http://svn.apache.org/viewvc?view=revrev=538024
Log:
Fixing the version and removing the .properties copying in the resources (that 
specified cli2)

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml?view=diffrev=538024r1=538023r2=538024
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/project.xml Mon May 14 
17:00:44 2007
@@ -18,7 +18,7 @@
   groupIdcommons-cli/groupId
   artifactIdcommons-cli/artifactId
   nameCLI/name
-  currentVersion2.0-SNAPSHOT/currentVersion
+  currentVersion1.1-SNAPSHOT/currentVersion
   inceptionYear2002/inceptionYear
   shortDescriptionCommons CLI/shortDescription
   description
@@ -158,17 +158,6 @@
 nagEmailAddresscommons-dev@jakarta.apache.org/nagEmailAddress
 sourceDirectorysrc/java/sourceDirectory
 unitTestSourceDirectorysrc/test/unitTestSourceDirectory
-integrationUnitTestSourceDirectory/
-aspectSourceDirectory/
-resources
-resource
-  directorysrc/java/org/apache/commons/cli2/directory
-  targetPathorg/apache/commons/cli2/targetPath
-  includes
-include**/*.properties/include
-  /includes
-/resource
-/resources
 
 !-- Unit test classes --
 unitTest



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r538025 - /jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 17:02:01 2007
New Revision: 538025

URL: http://svn.apache.org/viewvc?view=revrev=538025
Log:
Updating the build.xml with a new maven ant. This fixes the copying from a cli2 
directory, the repository location, an unnecessary jdepend dependency and all 
importantly, the version number. Thanks to Brian Egge in CLI-129 for this, 
though I ended up using his patch as a pointer to the parts of project.xml that 
needed fixing rather than a fix for the build.xml.

Modified:
jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml

Modified: jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml?view=diffrev=538025r1=538024r2=538025
==
--- jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml (original)
+++ jakarta/commons/proper/cli/branches/cli-1.0.x/build.xml Mon May 14 17:02:01 
2007
@@ -1,7 +1,7 @@
 ?xml version=1.0 encoding=UTF-8?
 
-!--build.xml generated by maven from project.xml version 2.0-SNAPSHOT
-  on date March 3 2006, time 1447--
+!--build.xml generated by maven from project.xml version 1.1-SNAPSHOT
+  on date May 14 2007, time 1658--
 
 project default=jar name=commons-cli basedir=.
   !--Load local and user build preferences--
@@ -26,7 +26,7 @@
   /property
   property name=javadocdir value=${basedir}/dist/docs/api
   /property
-  property name=final.name value=commons-cli-2.0-SNAPSHOT
+  property name=final.name value=commons-cli-1.1-SNAPSHOT
   /property
   property name=proxy.host value=
   /property
@@ -41,8 +41,6 @@
 /pathelement
 pathelement location=${libdir}/junit/jars/junit-3.8.1.jar
 /pathelement
-pathelement location=${libdir}/jdepend/jars/jdepend-2.5.jar
-/pathelement
   /path
   target name=init description=o Initializes some properties
 mkdir dir=${libdir}
@@ -79,14 +77,6 @@
   classpath refid=build.classpath
   /classpath
 /javac
-mkdir dir=${classesdir}/org/apache/commons/cli2
-/mkdir
-copy todir=${classesdir}/org/apache/commons/cli2
-  fileset dir=${basedir}/src/java/org/apache/commons/cli2
-include name=**/*.properties
-/include
-  /fileset
-/copy
   /target
   target name=jar description=o Create the jar depends=compile,test
 jar jarfile=${defaulttargetdir}/${final.name}.jar 
excludes=**/package.html basedir=${classesdir}
@@ -160,12 +150,6 @@
 /pathelement
   /classpath
 /javac
-copy todir=${testclassesdir}/org/apache/commons/cli2
-  fileset dir=${basedir}/src/test/org/apache/commons/cli2
-include name=**/*.properties
-/include
-  /fileset
-/copy
   /target
   target name=javadoc description=o Generate javadoc depends=get-deps
 mkdir dir=${javadocdir}
@@ -176,7 +160,7 @@
 /tstamp
 property name=copyright value=Copyright amp;copy;  Apache Software 
Foundation. All Rights Reserved.
 /property
-property name=title value=CLI 2.0-SNAPSHOT API
+property name=title value=CLI 1.1-SNAPSHOT API
 /property
 javadoc use=true private=true destdir=${javadocdir} author=true 
version=true sourcepath=${basedir}/src/java 
packagenames=org.apache.commons.*
   classpath
@@ -188,7 +172,7 @@
   target name=get-dep-commons-lang.jar description=o Download the 
dependency : commons-lang.jar unless=commons-lang.jar 
depends=init,setProxy,noProxy,get-custom-dep-commons-lang.jar
 mkdir dir=${libdir}/commons-lang/jars/
 /mkdir
-get dest=${libdir}/commons-lang/jars/commons-lang-2.1.jar 
usetimestamp=true ignoreerrors=true 
src=http://www.ibiblio.org/maven/commons-lang/jars/commons-lang-2.1.jar;
+get dest=${libdir}/commons-lang/jars/commons-lang-2.1.jar 
usetimestamp=true ignoreerrors=true 
src=http://repo1.maven.org/maven/commons-lang/jars/commons-lang-2.1.jar;
 /get
   /target
   target name=get-custom-dep-commons-lang.jar if=commons-lang.jar 
depends=init,setProxy,noProxy
@@ -200,7 +184,7 @@
   target name=get-dep-junit.jar description=o Download the dependency : 
junit.jar unless=junit.jar 
depends=init,setProxy,noProxy,get-custom-dep-junit.jar
 mkdir dir=${libdir}/junit/jars/
 /mkdir
-get dest=${libdir}/junit/jars/junit-3.8.1.jar usetimestamp=true 
ignoreerrors=true 
src=http://www.ibiblio.org/maven/junit/jars/junit-3.8.1.jar;
+get dest=${libdir}/junit/jars/junit-3.8.1.jar usetimestamp=true 
ignoreerrors=true 
src=http://repo1.maven.org/maven/junit/jars/junit-3.8.1.jar;
 /get
   /target
   target name=get-custom-dep-junit.jar if=junit.jar 
depends=init,setProxy,noProxy
@@ -209,19 +193,7 @@
 get dest=${libdir}/junit/jars/junit-3.8.1.jar usetimestamp=true 
ignoreerrors=true src=${junit.jar}
 /get
   /target
-  target name=get-dep-jdepend.jar description=o Download the dependency : 
jdepend.jar unless=jdepend.jar 
depends=init,setProxy,noProxy,get-custom-dep-jdepend.jar
-mkdir dir=${libdir

svn commit: r538031 - in /jakarta/commons/proper/cli/branches/cli-1.0.x/src: java/org/apache/commons/cli/CommandLine.java java/org/apache/commons/cli/Option.java test/org/apache/commons/cli/bug/BugCLI

2007-05-14 Thread bayard
Author: bayard
Date: Mon May 14 17:47:38 2007
New Revision: 538031

URL: http://svn.apache.org/viewvc?view=revrev=538031
Log:
Applying Brian Egge's fix and unit test from CLI-13. 

Added:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/test/org/apache/commons/cli/bug/BugCLI13Test.java
Modified:

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java

jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java?view=diffrev=538031r1=538030r2=538031
==
--- 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java
 (original)
+++ 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/CommandLine.java
 Mon May 14 17:47:38 2007
@@ -16,11 +16,11 @@
 package org.apache.commons.cli;
 
 import java.util.Collection;
-import java.util.HashMap;
 import java.util.Iterator;
 import java.util.LinkedList;
 import java.util.List;
-import java.util.Map;
+import java.util.Set;
+import java.util.HashSet;
 
 /** 
  * pRepresents list of arguments parsed against
@@ -43,16 +43,10 @@
 private List args = new LinkedList();
 
 /** the processed options */
-private Map options = new HashMap();
-
-/** the option name map */
-private Map names = new HashMap();
+private Set options = new HashSet();
 
 /** Map of unique options for ease to get complete list of options */
-private Map hashcodeMap = new HashMap();
-
-/** the processed options */
-private Option[] optionsArray;
+//private Set allOptions = new HashSet();
 
 /**
  * Creates a command line.
@@ -70,7 +64,7 @@
  */
 public boolean hasOption(String opt)
 {
-return options.containsKey(opt);
+return options.contains( resolveOption(opt));
 }
 
 /** 
@@ -94,12 +88,13 @@
 {
 String res = getOptionValue(opt);
 
-if (!options.containsKey(opt))
+Option option = resolveOption(opt);
+if (option == null)
 {
 return null;
 }
 
-Object type = ((Option) options.get(opt)).getType();
+Object type = option.getType();
 
 return (res == null)? null : TypeHandler.createValue(res, 
type);
 }
@@ -150,20 +145,37 @@
  */
 public String[] getOptionValues(String opt)
 {
-opt = Util.stripLeadingHyphens(opt);
-
-String key = opt;
+Option key = resolveOption( opt );
 
-if (names.containsKey(opt))
+if (options.contains(key))
 {
-key = (String) names.get(opt);
+return key.getValues();
 }
 
-if (options.containsKey(key))
+return null;
+}
+
+/**
+ * pRetrieves the option object given the long or short option as a 
String/p
+ * @param opt short or long name of the option
+ * @return Canonicalized option
+ */
+private Option resolveOption( String opt )
+{
+opt = Util.stripLeadingHyphens(opt);
+for ( Iterator it = options.iterator(); it.hasNext(); )
 {
-return ((Option) options.get(key)).getValues();
+Option option = (Option) it.next();
+if (opt.equals(option.getOpt()))
+{
+return option;
+}
+if (opt.equals( option.getLongOpt()))
+{
+return option;
 }
 
+}
 return null;
 }
 
@@ -273,20 +285,7 @@
  */
 void addOption(Option opt)
 {
-hashcodeMap.put(new Integer(opt.hashCode()), opt);
-
-String key = opt.getKey();
-
-if (key == null)
-{
-key = opt.getLongOpt();
-}
-else
-{
-names.put(opt.getLongOpt(), key);
-}
-
-options.put(key, opt);
+options.add(opt);
 }
 
 /**
@@ -297,7 +296,7 @@
  */
 public Iterator iterator()
 {
-return hashcodeMap.values().iterator();
+return options.iterator();
 }
 
 /**
@@ -307,11 +306,10 @@
  */
 public Option[] getOptions()
 {
-Collection processed = options.values();
-
+Collection processed = options;
 
 // reinitialise array
-optionsArray = new Option[processed.size()];
+Option[] optionsArray = new Option[processed.size()];
 
 // return the array
 return (Option[]) processed.toArray(optionsArray);

Modified: 
jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/cli/branches/cli-1.0.x/src/java/org/apache/commons/cli/Option.java

svn commit: r534976 - in /jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections: ./ buffer/ collection/ list/ map/

2007-05-03 Thread bayard
Author: bayard
Date: Thu May  3 12:54:44 2007
New Revision: 534976

URL: http://svn.apache.org/viewvc?view=revrev=534976
Log:
Applying Mark Hindess' patch from COLLECTIONS-232 that cleans up the ordering 
of various assertEquals to be expected,actual and not actual,expected and also 
fixes various assertEquals to assertNulls where applicable

Modified:

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayList.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayStack.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestCollectionUtils.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestExtendedProperties.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestMapUtils.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestTreeMap.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/buffer/TestPredicatedBuffer.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/collection/AbstractTestCollection.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/collection/TestCompositeCollection.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/list/AbstractTestList.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/map/AbstractTestMap.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/map/TestCaseInsensitiveMap.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/map/TestLazySortedMap.java

jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/map/TestPredicatedSortedMap.java

Modified: 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayList.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayList.java?view=diffrev=534976r1=534975r2=534976
==
--- 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayList.java
 (original)
+++ 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayList.java
 Thu May  3 12:54:44 2007
@@ -54,7 +54,7 @@
 //---
 public void testNewArrayList() {
 assertTrue(New list is empty, list.isEmpty());
-assertEquals(New list has size zero, list.size(), 0);
+assertEquals(New list has size zero, 0, list.size());
 
 try {
 list.get(1);
@@ -67,8 +67,8 @@
 public void testSearch() {
 list.add(First Item);
 list.add(Last Item);
-assertEquals(First item is 'First Item', list.get(0), First Item);
-assertEquals(Last Item is 'Last Item', list.get(1), Last Item);
+assertEquals(First item is 'First Item', First Item, list.get(0));
+assertEquals(Last Item is 'Last Item', Last Item, list.get(1));
 }
 
 }

Modified: 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayStack.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayStack.java?view=diffrev=534976r1=534975r2=534976
==
--- 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayStack.java
 (original)
+++ 
jakarta/commons/proper/collections/trunk/src/test/org/apache/commons/collections/TestArrayStack.java
 Thu May  3 12:54:44 2007
@@ -58,7 +58,7 @@
 public void testNewStack() {
 
 assertTrue(New stack is empty, stack.empty());
-assertEquals(New stack has size zero, stack.size(), 0);
+assertEquals(New stack has size zero, 0, stack.size());
 
 try {
 stack.peek();
@@ -80,26 +80,26 @@
 
 stack.push(First Item);
 assertTrue(Stack is not empty, !stack.empty());
-assertEquals(Stack size is one, stack.size(), 1);
+assertEquals(Stack size is one, 1, stack.size());
 assertEquals(Top item is 'First Item',
- (String) stack.peek(), First Item);
-assertEquals(Stack size is one, stack.size(), 1);
+ First Item, (String) stack.peek());
+assertEquals(Stack size is one, 1, stack.size());
 
 stack.push(Second Item);
-assertEquals(Stack size is two, stack.size(), 2);
+assertEquals(Stack size is two, 2, stack.size());
 assertEquals(Top item is 'Second Item',
- (String) stack.peek

svn commit: r534588 - in /jakarta/commons/proper/lang/trunk/src: java/org/apache/commons/lang/ test/org/apache/commons/lang/ test/org/apache/commons/lang/math/

2007-05-02 Thread bayard
Author: bayard
Date: Wed May  2 11:46:07 2007
New Revision: 534588

URL: http://svn.apache.org/viewvc?view=revrev=534588
Log:
Adding 'Deprecated' to tests which are testing deprecated methods and moving 
CharSetUtils from the deprecated evaluateSet method to a new 
getInstance(String[]) method. This does mean that getInstance(null) is no 
longer going to compile for people - they'll need to cast the null. 

Modified:

jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSet.java

jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSetUtils.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/CharSetTest.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/StringUtilsSubstringTest.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/StringUtilsTest.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/StringUtilsTrimEmptyTest.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/SystemUtilsTest.java

jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/math/NumberUtilsTest.java

Modified: 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSet.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSet.java?view=diffrev=534588r1=534587r2=534588
==
--- 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSet.java 
(original)
+++ 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSet.java 
Wed May  2 11:46:07 2007
@@ -146,6 +146,19 @@
 return new CharSet(setStr);
 }
 
+/**
+ * pConstructs a new CharSet using the set syntax.
+ * Each string is merged in with the set./p
+ *
+ * @param set  Strings to merge into the initial set, may be null
+ */
+public static CharSet getInstance(String[] setStrs) {
+if (setStrs == null) {
+return null;
+}
+return new CharSet(setStrs); 
+}
+
 //---
 /**
  * pConstructs a new CharSet using the set syntax./p

Modified: 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSetUtils.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSetUtils.java?view=diffrev=534588r1=534587r2=534588
==
--- 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSetUtils.java
 (original)
+++ 
jakarta/commons/proper/lang/trunk/src/java/org/apache/commons/lang/CharSetUtils.java
 Wed May  2 11:46:07 2007
@@ -63,7 +63,7 @@
  *
  * @param set  the set, may be null
  * @return a CharSet instance, codenull/code if null input
- * @deprecated Use [EMAIL PROTECTED] CharSet#getInstance(String)}.
+ * @deprecated Use [EMAIL PROTECTED] CharSet#getInstance(String[])}.
  * Method will be removed in Commons Lang 3.0.
  */
 public static CharSet evaluateSet(String[] set) {
@@ -120,7 +120,7 @@
 if (StringUtils.isEmpty(str) || ArrayUtils.isEmpty(set)) {
 return str;
 }
-CharSet chars = evaluateSet(set);
+CharSet chars = CharSet.getInstance(set);
 StringBuffer buffer = new StringBuffer(str.length());
 char[] chrs = str.toCharArray();
 int sz = chrs.length;
@@ -186,7 +186,7 @@
 if (StringUtils.isEmpty(str) || ArrayUtils.isEmpty(set)) {
 return 0;
 }
-CharSet chars = evaluateSet(set);
+CharSet chars = CharSet.getInstance(set);
 int count = 0;
 char[] chrs = str.toCharArray();
 int sz = chrs.length;
@@ -318,7 +318,7 @@
  * @return modified String
  */
 private static String modify(String str, String[] set, boolean expect) {
-CharSet chars = evaluateSet(set);
+CharSet chars = CharSet.getInstance(set);
 StringBuffer buffer = new StringBuffer(str.length());
 char[] chrs = str.toCharArray();
 int sz = chrs.length;

Modified: 
jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/CharSetTest.java
URL: 
http://svn.apache.org/viewvc/jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/CharSetTest.java?view=diffrev=534588r1=534587r2=534588
==
--- 
jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/CharSetTest.java
 (original)
+++ 
jakarta/commons/proper/lang/trunk/src/test/org/apache/commons/lang/CharSetTest.java
 Wed May  2 11:46:07 2007
@@ -64,7 +64,7 @@
 
 //---
 public void testGetInstance() {
-assertSame

svn commit: r534205 - /jakarta/commons/proper/lang/branches/Lang2-1.x/

2007-05-01 Thread bayard
Author: bayard
Date: Tue May  1 12:12:29 2007
New Revision: 534205

URL: http://svn.apache.org/viewvc?view=revrev=534205
Log:
Copying the current trunk of Lang for a research branch into Lang2

Added:
jakarta/commons/proper/lang/branches/Lang2-1.x/
  - copied from r534204, jakarta/commons/proper/lang/trunk/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  1   2   3   4   5   6   7   8   9   10   >