public interface ImapSession
Modifier and Type | Method and Description |
---|---|
void |
authenticated()
Moves the session into
ImapSessionState.AUTHENTICATED state. |
void |
deselect()
Moves the session out of
ImapSessionState.SELECTED state and back
into ImapSessionState.AUTHENTICATED state. |
Object |
getAttribute(String key)
Gets an attribute of this session by name.
|
org.slf4j.Logger |
getLog()
Gets the context sensitive log for this session.
|
SelectedMailbox |
getSelected()
Provides the selected mailbox for this session, or
null if
this session is not in ImapSessionState.SELECTED state. |
ImapSessionState |
getState()
Gets the current client state.
|
boolean |
isCompressionActive()
Return true if compression is active
|
boolean |
isCompressionSupported()
Return true if compression is supported.
|
boolean |
isPlainAuthDisallowed()
Return true if the login / authentication via plain username / password is
disallowed
|
boolean |
isTLSActive()
Return true if the session is bound to a TLS encrypted socket.
|
void |
logout()
Logs out the session.
|
void |
popLineHandler()
Pop the current
ImapLineHandler |
void |
pushLineHandler(ImapLineHandler lineHandler)
Push in a new
ImapLineHandler which is called for the next line received |
void |
selected(SelectedMailbox mailbox)
Moves this session into
ImapSessionState.SELECTED state and sets
the supplied mailbox to be the currently selected mailbox. |
void |
setAttribute(String key,
Object value)
Sets an attribute of this session by name.
|
boolean |
startCompression()
Start the compression
|
boolean |
startTLS()
Start TLS encryption of the session after the next response was written.
|
boolean |
supportMultipleNamespaces()
Return true if multiple namespaces are supported
|
boolean |
supportStartTLS()
Support startTLS ?
|
org.slf4j.Logger getLog()
void logout()
ImapSessionState getState()
void authenticated()
ImapSessionState.AUTHENTICATED
state.void selected(SelectedMailbox mailbox)
ImapSessionState.SELECTED
state and sets
the supplied mailbox to be the currently selected mailbox.mailbox
- The selected mailbox.void deselect()
ImapSessionState.SELECTED
state and back
into ImapSessionState.AUTHENTICATED
state. The selected mailbox
is cleared.SelectedMailbox getSelected()
null
if
this session is not in ImapSessionState.SELECTED
state.Object getAttribute(String key)
key
- name of the key, not nullObject
value or null if this attribute has unvaluedvoid setAttribute(String key, Object value)
key
- name of the key, not nullvalue
- Object
value or null to set this attribute as
unvaluedboolean startTLS()
boolean isTLSActive()
boolean supportStartTLS()
boolean isCompressionActive()
boolean isCompressionSupported()
boolean startCompression()
boolean supportMultipleNamespaces()
boolean isPlainAuthDisallowed()
void pushLineHandler(ImapLineHandler lineHandler)
ImapLineHandler
which is called for the next line receivedlineHandler
- void popLineHandler()
ImapLineHandler
Copyright © 2010-2012 The Apache Software Foundation. All Rights Reserved.