final Map<String, String> clientParams = new HashMap<String, String>();
clientParams.put("name", "my-imap");
clientParams.put("version", "1.0");
imapFolder.doOptionalCommand("ID not supported",
new IMAPFolder.ProtocolCommand() {
@Override
public Object doCommand(IMAPProtocol p)
throws ProtocolException {
return p.id(clientParams);
}
});
imapFolder.open(Folder.READ_ONLY);
版权声明:本文为CSDN博主「lennonchan」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/lennonchan/java/article/details/81005626