Article View: borland.public.jbuilder.java.api
Article #1456Re: Javamail works under Jbuilder but not under command line
From: Roy McBrayer
Date: Wed, 12 Dec 2001 14:40
Date: Wed, 12 Dec 2001 14:40
34 lines
2339 bytes
2339 bytes
Thanks a bunch Roy "R.F. Pels" <ruurd@acklin.nl> wrote: >Owen Green wrote: > >>> The Activation Framework jar is imported as a package and is included in >>> an import statement in the program. I can see it >is included when >>> JBuilder creates the classpath. > >So you import the classes from mail.jar and smtp.jar etcetera so you can >deploy it as one jar. The JavaMail documentation says you cannot do that, >but actually you can. If you need for example smtp and pop3 in JavaMail to >do your thing, you must include all the classes from the smtp.jar and >pop3.jar, but you must also add the following property files from the >JavaMail jar to your own jar otherwise it will not work: > > META-INF/javamail.charset.map > META-INF/javamail.default.address.map > META-INF/javamail.default.providers > META-INF/mailcap > >Actually what I did was to put imap.jar, smtp.jar, pop3.jar and mail.jar >from JavaMail in one JBuilder library, Java Activation Framework in another >JBuilder library and added them to the target jar telling it to include ALL >classes. I also extracted the above files and placed them in a new META-INF >directory directly below my source path and added all four of them >manually. If you do this, it will work flawlessly. > > >-- > >Ruurd
Technical Details
Message-ID:
<3c176c5b$1_2@dnews>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!news.maxwell.syr.edu!newsfeed.media.kyoto-u.ac.jp!newsfeed.mesh.ad.jp!uunet!osa.uu.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnewsReferences:
<3c1628d1$1_2@dnews> <3c163164_2@dnews> <3c164c7f$1_1@dnews> <3c16556e$1_1@dnews> <3c168b3f_2@dnews>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,6ccd96b37f5aca63 X-Google-Attributes: gid1089d0,public X-Google-ArrivalTime: 2001-12-12 06:56:21 PST From: "Roy McBrayer" <roymcbrayer@mail.va.gov> Sender: "Roy McBrayer" <roymcbrayer@mail.va.gov> Reply-To: "Roy McBrayer" <roymcbrayer@mail.va.gov> Subject: Re: Javamail works under Jbuilder but not under command line Newsgroups: borland.public.jbuilder.java.api X-User-Info: 63.160.3.152 63.160.3.152 References: <3c1628d1$1_2@dnews> <3c163164_2@dnews> <3c164c7f$1_1@dnews> <3c16556e$1_1@dnews> <3c168b3f_2@dnews> NNTP-Posting-Host: 207.105.83.65 Message-ID: <3c176c5b$1_2@dnews> Date: 12 Dec 2001 06:40:27 -0800 X-Trace: dnews 1008168027 207.105.83.65 (12 Dec 2001 06:40:27 -0800) Lines: 35 Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!news.maxwell.syr.edu!newsfeed.media.kyoto-u.ac.jp!newsfeed.mesh.ad.jp!uunet!osa.uu.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnews