java.lang.AutoCloseable
POP3SSLStore
public class POP3Store
extends javax.mail.Store
Modifier and Type | Method | Description |
---|---|---|
java.util.Map<java.lang.String,java.lang.String> |
capabilities() |
Return a Map of the capabilities the server provided,
as per RFC 2449.
|
void |
close() |
|
protected void |
finalize() |
|
javax.mail.Folder |
getDefaultFolder() |
|
javax.mail.Folder |
getFolder(java.lang.String name) |
Only the name "INBOX" is supported.
|
javax.mail.Folder |
getFolder(javax.mail.URLName url) |
|
boolean |
isConnected() |
Check whether this store is connected.
|
boolean |
isSSL() |
Is this POP3Store using SSL to connect to the server?
|
protected boolean |
protocolConnect(java.lang.String host,
int portNum,
java.lang.String user,
java.lang.String passwd) |
addFolderListener, addStoreListener, getPersonalNamespaces, getSharedNamespaces, getUserNamespaces, notifyFolderListeners, notifyFolderRenamedListeners, notifyStoreListeners, removeFolderListener, removeStoreListener
public POP3Store(javax.mail.Session session, javax.mail.URLName url)
public POP3Store(javax.mail.Session session, javax.mail.URLName url, java.lang.String name, boolean isSSL)
protected boolean protocolConnect(java.lang.String host, int portNum, java.lang.String user, java.lang.String passwd) throws javax.mail.MessagingException
protocolConnect
in class javax.mail.Service
javax.mail.MessagingException
public boolean isConnected()
isConnected
in class javax.mail.Service
public void close() throws javax.mail.MessagingException
close
in interface java.lang.AutoCloseable
close
in class javax.mail.Service
javax.mail.MessagingException
public javax.mail.Folder getDefaultFolder() throws javax.mail.MessagingException
getDefaultFolder
in class javax.mail.Store
javax.mail.MessagingException
public javax.mail.Folder getFolder(java.lang.String name) throws javax.mail.MessagingException
getFolder
in class javax.mail.Store
javax.mail.MessagingException
public javax.mail.Folder getFolder(javax.mail.URLName url) throws javax.mail.MessagingException
getFolder
in class javax.mail.Store
javax.mail.MessagingException
public java.util.Map<java.lang.String,java.lang.String> capabilities() throws javax.mail.MessagingException
For example, to check if the server supports the STLS capability, use:
if (store.capabilities().containsKey("STLS")) ...
javax.mail.MessagingException
- for failurespublic boolean isSSL()
protected void finalize() throws java.lang.Throwable
finalize
in class javax.mail.Service
java.lang.Throwable