commons-io has refactored filename methods out of org.apache.commons.io.FileUtils into org.apache.commons.io.FilenameUtils.
And in FilenameUtils dirname is deprecated and replaced by dirPath.
So I attach a patch of org.apache.commons.xo.Mapper.
Can you please commit the patch, this will please our friend gump. :-)
Cheers,
Antoine
dIon Gillard wrote:
To whom it may engage...
....
Project commons-xo has an issue affecting it's community integration. The current state is 'Failed', for reason 'Build Failed'
Full details are available at: http://lsd.student.utwente.nl/gump/jakarta-commons-sandbox/commons-xo.html, however some snippets follow:
[javac] Compiling 1 source file to /data3/gump/jakarta-commons-sandbox/xo/target/classes [javac] /data3/gump/jakarta-commons-sandbox/xo/src/java/org/apache/commons/xo/Mapper.java:185: cannot resolve symbol [javac] symbol : method dirname (java.lang.String) [javac] location: class org.apache.commons.io.FileUtils [javac] basePath = FileUtils.dirname(xmlInput.getAbsolutePath()); [javac] ^ [javac] /data3/gump/jakarta-commons-sandbox/xo/src/java/org/apache/commons/xo/Mapper.java:220: cannot resolve symbol [javac] symbol : method dirname (java.lang.String) [javac] location: class org.apache.commons.io.FileUtils [javac] basePath = FileUtils.dirname(xmlInput); [javac] ^ [javac] 2 errors
BUILD FAILED
Index: xo/src/java/org/apache/commons/xo/Mapper.java
===================================================================
RCS file:
/home/cvspublic/jakarta-commons-sandbox/xo/src/java/org/apache/commons/xo/Mapper.java,v
retrieving revision 1.5
diff -u -r1.5 Mapper.java
--- xo/src/java/org/apache/commons/xo/Mapper.java 28 Feb 2004 03:35:56 -0000
1.5
+++ xo/src/java/org/apache/commons/xo/Mapper.java 5 Mar 2004 21:45:26 -0000
@@ -33,7 +33,7 @@
import org.apache.commons.beanutils.ConvertUtils;
import org.apache.commons.beanutils.MethodUtils;
-import org.apache.commons.io.FileUtils;
+import org.apache.commons.io.FilenameUtils;
import org.apache.commons.lang.StringUtils;
@@ -182,7 +182,7 @@
throws Exception
{
// Get the base directory
- basePath = FileUtils.dirname(xmlInput.getAbsolutePath());
+ basePath = FilenameUtils.getPath(xmlInput.getAbsolutePath());
return map(new FileInputStream(xmlInput), beanClass);
}
@@ -217,7 +217,7 @@
InputStream xmlStream = findXmlStream(xmlInput);
// Get the base directory
- basePath = FileUtils.dirname(xmlInput);
+ basePath = FilenameUtils.getPath(xmlInput);
return map(xmlStream, beanClass);
}
@@ -271,7 +271,7 @@
* <code>className</code> attribute of the first <code>Node</code>
* in the XML document.
* @return The modified instance of <code>bean</code>.
- * @exception DocumentException If the buildprocess fails.
+ * @exception org.dom4j.DocumentException If the buildprocess fails.
*/
public Object map(InputStream xmlInput, Object bean)
throws Exception
@@ -290,7 +290,7 @@
* <code>className</code> attribute of the first <code>Node</code>
* in the XML document.
* @return The fleshed-out instance of <code>beanClass</code>.
- * @exception DocumentException If the build process fails.
+ * @exception org.dom4j.DocumentException If the build process fails.
*/
public Object map(InputStream xmlInput, String beanClass)
throws Exception
@@ -309,7 +309,7 @@
* and populate.
* @return The modified <code>bean</code> instance or the fleshed-out
* instance of <code>beanClass</code>
- * @exception DocumentException If the build process fails.
+ * @exception org.dom4j.DocumentException If the build process fails.
*/
protected Object map(InputStream xmlInput, Object bean, String beanClass)
throws Exception
@@ -761,7 +761,7 @@
* <p>
* FIXME: This cannot be easily I18N'd
*
- * @param String name to test for plurality
+ * @param name to test for plurality
* @return boolean
*/
private boolean isPlural(String name)--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
