Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > JWebmail compiled error in build.xml.

Reply
Thread Tools

JWebmail compiled error in build.xml.

 
 
sam
Guest
Posts: n/a
 
      06-21-2004
Hi,

Does anyone know how to fix the following error? I try to install
JWebmail in FreeBSD 5.2 Current.

Thanks
sam

Please see attached message below:
........
compile:
[javac] Compiling 87 source files to
/usr/local/jwebmail-0.7/build/classes
[javac] Note: sun.tools.javac.Main has been deprecated.
[javac]
/usr/local/jwebmail-0.7/build/src/net/wastl/webmail/xml/XMLCommon.java:61:
Ambiguous class: java.lang.CharacterData and org.w3c.dom.CharacterData
[javac] if(nl.item(i) instanceof CharacterData) {
[javac] ^
[javac]
/usr/local/jwebmail-0.7/build/src/net/wastl/webmail/xml/XMLCommon.java:85:
Ambiguous class: java.lang.CharacterData and org.w3c.dom.CharacterData
[javac] if(nl.item(i) instanceof CharacterData) {
[javac] ^
[javac]
/usr/local/jwebmail-0.7/build/src/net/wastl/webmail/server/WebMailSession.java:979:
Note: The method java.lang.String encode(java.lang.String) in class
java.net.URLEncoder has been deprecated.
[javac] xml_part.setAttribute("hrefFileName",
URLEncoder.encode(new String(name.getBytes("UTF-8"), "ISO8859_1")));
[javac] ^
[javac]
/usr/local/jwebmail-0.7/build/src/net/wastl/webmail/server/http/HTTPRequestHeader.java:44:
Note: The method java.lang.String decode(java.lang.String) in class
java.net.URLDecoder has been deprecated.
[javac] setHeader("PATH",URLDecoder.decode(s));
[javac] ^
[javac] Note: 2 files use or override a deprecated API. Please
consult the documentation for a better alternative in each case.
[javac] 2 errors, 2 warnings

BUILD FAILED

/usr/local/jwebmail-0.7/build.xml:191: Compile failed, messages should
have been provided.

Total time: 2 minutes 2 seconds
root@fbsd [3:03am] [...local/jwebmail-0.7]#

 
Reply With Quote
 
 
 
 
Roedy Green
Guest
Posts: n/a
 
      06-21-2004
On Tue, 22 Jun 2004 03:31:26 +0800, sam <(E-Mail Removed)>
wrote or quoted :

>Ambiguous class: java.lang.CharacterData and org.w3c.dom.CharacterData
> [javac] if(nl.item(i) instanceof CharacterData) {


Which class did you mean? Since the goofs reused the class name, you
must spell it out longhand:

instanceof org.w3c.dom.CharaterData
or
instanceof java.lang.CharacterData


--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
 
Reply With Quote
 
 
 
 
Roedy Green
Guest
Posts: n/a
 
      06-21-2004
On Tue, 22 Jun 2004 03:31:26 +0800, sam <(E-Mail Removed)>
wrote or quoted :

>URLEncoder.encode(new String(name.getBytes("UTF-8"), "ISO8859_1")));


URLEncoder is for Strings with few awkward chars. To send arbitrary
bytes you need something a bit more heavy duty. See
http://mindprod.com/jgloss/armouring.html

Further, URLEncoder should always be used with UTF-8. You have tried
to use it with ISO8859_1.

if name is a String, what you should have written is:

String send = URLEncoder.encode( name, "UTF-8" );

if name is a byte array, you should have written:

String send = URLEncoder.encode( new String( name, "UTF-8" ),
"UTF-8");


if name is something else that can be converted to byte array you
should have written.


String send = URLEncoder.encode( new String( name.toBytes(), "UTF-8"
), "UTF-8");

But this is not what URLEncoder is for. Try the Base64u or the
Wrapper, both described at http://mindprod.com/jgloss/armouring.html
--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
If I create a page, then it's compiled upon first request, where cani find the compiled code?? lander ASP .Net 5 03-05-2008 04:34 PM
not been pre-compiled error ad ASP .Net 1 04-02-2006 11:39 AM
JSP on ServletExec Error getting compiled page chadn Java 0 03-01-2005 11:58 PM
g++ compiled C++ code called from gcc compiled C code Klaus Schneider C++ 1 12-02-2004 01:44 PM
Error saving .aspx compiled state -> access denied bruce barker ASP .Net 2 07-19-2004 09:24 AM



Advertisments