hi, the following code is working fine when I am running it as an application.I am working on linux platform.but the same code shows ClassCastException at run time when i am running it inside my application which is running inside the web server as a .war file.please help me.
Hi, PJ, and Welcome to JavaRanch! You might try the following line: System.out.println(theStore.getClass().getName()); to see what class you are actually working with, and wheter or not it can be cast to an IMAPStore. Please note the following from the IMAPStore javadoc (I assume that you are using SUN's): WARNING: The APIs unique to this class should be considered EXPERIMENTAL. They may be changed in the future in ways that are incompatible with applications using the current APIs. (This holds true for pretty much anything in the com.sun.* packages; SUN actively discourages their use, as they are prone to sudden, unannounced changes. SUN does not consider them part of the public API)
Piscis Babelis est parvus, flavus, et hiridicus, et est probabiliter insolitissima raritas in toto mundo.