I am trying to get password reset link which is sent to email
System.out.println("Email Number " + (i + 1));
System.out.println("Subject: " + message.getSubject());
System.out.println("From: " + message.getFrom()[0]);
System.out.println("Text: " + message.getContent().toString());
System.out.println("link: " + message.getDescription());
Ouput:
Email Number 2
Subject: Welcome to Application
From: abc xyz
Text: javax.mail.internet.MimeMultipart@185d8b6
link: null
message
and why do you expect getting link by callinggetDescription()
? – Alexey R. Sep 21 '18 at 11:51