public final class POP3Store extends Store
Constructor and Description |
---|
POP3Store(Session session,
URLName urlname)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the connection.
|
Folder |
getDefaultFolder()
Returns the root folder.
|
Folder |
getFolder(java.lang.String s)
Returns the folder with the specified name.
|
Folder |
getFolder(URLName urlname)
Returns the folder whose name is the file part of the specified URLName.
|
protected javax.net.ssl.TrustManager |
getTrustManager()
Returns a trust manager used for TLS negotiation.
|
boolean |
isConnected()
Issues a NOOP to the POP server to determine whether the connection
is still alive.
|
protected boolean |
protocolConnect(java.lang.String host,
int port,
java.lang.String username,
java.lang.String password)
Connects to the POP3 server and authenticates with the specified
parameters.
|
addFolderListener, addStoreListener, getPersonalNamespaces, getSharedNamespaces, getUserNamespaces, notifyFolderListeners, notifyFolderRenamedListeners, notifyStoreListeners, removeFolderListener, removeStoreListener
addConnectionListener, connect, connect, connect, connect, getURLName, notifyConnectionListeners, queueEvent, removeConnectionListener, setConnected, setURLName, toString
protected boolean protocolConnect(java.lang.String host, int port, java.lang.String username, java.lang.String password) throws MessagingException
protocolConnect
in class Service
host
- the name of the host to connect toport
- the port to use (-1 for the default port)username
- the usernamepassword
- the passwordAuthenticationFailedException
- on authentication failureMessagingException
- for non-authentication failuresprotected javax.net.ssl.TrustManager getTrustManager() throws MessagingException
MessagingException
public void close() throws MessagingException
close
in class Service
MessagingException
public boolean isConnected()
isConnected
in class Service
public Folder getDefaultFolder() throws MessagingException
getDefaultFolder
in class Store
MessagingException
public Folder getFolder(java.lang.String s) throws MessagingException
getFolder
in class Store
s
- the folder nameMessagingException
public Folder getFolder(URLName urlname) throws MessagingException
getFolder
in class Store
urlname
- a URLName denoting a folderMessagingException