pb de package import - Java - Programmation
Marsh Posté le 21-05-2004 à 11:23:54
davidemb a écrit : voila g un pti souci a ma compilation et je trouve pa le bon package ou le import a mettre |
les classes que tu utilises pour lesquelles la compilation gueule, elle sont dans un package ... bon ben au début de ton fichier (après la close package tonPackage, il faut que tu mettes import lePackageDeLaClassQueTuUtilise.*;
Marsh Posté le 21-05-2004 à 13:03:58
davidemb a écrit : ben oui mais kel package, jle trouve pas |
tu ne connais pas le package des classes que tu utilises ?
Marsh Posté le 21-05-2004 à 11:19:43
voila g un pti souci a ma compilation et je trouve pa le bon package ou le import a mettre voila les erreurs :
RecupMail.java:59: cannot resolve symbol
symbol : class SimpleAuthenticator
location: class RecupMail
SimpleAuthenticator auth = new SimpleAuthenticator(username, passwor
d);
^
RecupMail.java:59: cannot resolve symbol
symbol : class SimpleAuthenticator
location: class RecupMail
SimpleAuthenticator auth = new SimpleAuthenticator(username, passwor
d);
^
RecupMail.java:60: cannot resolve symbol
symbol : class Session
location: class RecupMail
Session session = Session.getDefaultInstance(System.getProperties(),
auth);
^
RecupMail.java:60: cannot resolve symbol
symbol : variable Session
location: class RecupMail
Session session = Session.getDefaultInstance(System.getProperties(),
auth);
^
RecupMail.java:61: cannot resolve symbol
symbol : class URLName
location: class RecupMail
URLName urln = new URLName(urlstring);
^
RecupMail.java:61: cannot resolve symbol
symbol : class URLName
location: class RecupMail
URLName urln = new URLName(urlstring);
^
RecupMail.java:62: cannot resolve symbol
symbol : class Store
location: class RecupMail
Store store = session.getStore(urln);
^
RecupMail.java:64: cannot resolve symbol
symbol : class Folder
location: class RecupMail
Folder folder = store.getDefaultFolder();
^
RecupMail.java:65: cannot resolve symbol
symbol : class POP3Folder
location: class RecupMail
POP3Folder fol = (POP3Folder)folder.getFolder("INBOX" );
^
RecupMail.java:65: cannot resolve symbol
symbol : class POP3Folder
location: class RecupMail
POP3Folder fol = (POP3Folder)folder.getFolder("INBOX" );
^
RecupMail.java:67: cannot resolve symbol
symbol : class Message
location: class RecupMail
Message listmes[] = fol.getMessages();
^
RecupMail.java:84: cannot resolve symbol
symbol : class POP3Message
location: class RecupMail
POP3Message msg = (POP3Message)listmes[i];
^
RecupMail.java:84: cannot resolve symbol
symbol : class POP3Message
location: class RecupMail
POP3Message msg = (POP3Message)listmes[i];
^
RecupMail.java:85: package javax.mail.Flags does not exist
msg.setFlag(javax.mail.Flags.Flag.SEEN, true);
^
RecupMail.java:109: package javax.mail.Message does not exist
mail.setTo(msg.getRecipients(javax.mail.Message.Reci
pientType.TO)[0].toString());
^
RecupMail.java:147: cannot resolve symbol
symbol : class Multipart
location: class RecupMail
if(msg.getDataHandler().getContent() instanceof Multipar
t)
^
RecupMail.java:149: cannot resolve symbol
symbol : class Multipart
location: class RecupMail
Multipart mp = (Multipart)msg.getDataHandler().getCo
ntent();
^
RecupMail.java:149: cannot resolve symbol
symbol : class Multipart
location: class RecupMail
Multipart mp = (Multipart)msg.getDataHandler().getCo
ntent();
^
RecupMail.java:153: cannot resolve symbol
symbol : class BodyPart
location: class RecupMail
BodyPart bp = mp.getBodyPart(j);
^
RecupMail.java:156: cannot resolve symbol
symbol : class Multipart
location: class RecupMail
while(bp.getDataHandler().getContent() insta
nceof Multipart)
^
RecupMail.java:158: cannot resolve symbol
symbol : class Multipart
location: class RecupMail
bp = ((Multipart)bp.getDataHandler().get
Content()).getBodyPart(0);
^
Pouvez vous m'aider????