public class ImapConnection extends AbstractConnection
Modifier and Type | Class and Description |
---|---|
protected static class |
ImapConnection.AbstractRangeIterator |
protected static class |
ImapConnection.RangeIterator |
protected static class |
ImapConnection.UIDRangeIterator |
AbstractConnection.LineReaderInputStream, AbstractConnection.State
Thread.UncaughtExceptionHandler
Modifier and Type | Field and Description |
---|---|
protected String |
baseMailboxPath |
protected String |
lastCommand |
protected int |
lastCommandCount |
client, in, os, password, session, state, userName
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Constructor and Description |
---|
ImapConnection(Socket clientSocket)
Initialize the streams and start the thread.
|
Modifier and Type | Method and Description |
---|---|
protected void |
appendBodyStructure(StringBuilder buffer,
davmail.imap.ImapConnection.MessageWrapper message) |
protected void |
appendBodyStructure(StringBuilder buffer,
javax.mail.internet.MimeMultipart multiPart) |
protected void |
appendBodyStructure(StringBuilder buffer,
javax.mail.internet.MimePart bodyPart) |
protected void |
appendBodyStructureValue(StringBuilder buffer,
int value) |
protected void |
appendBodyStructureValue(StringBuilder buffer,
String value) |
protected ExchangeSession.Condition |
appendDateSearchParam(davmail.imap.ImapConnection.ImapTokenizer tokens,
String token) |
protected void |
appendEnvelope(StringBuilder buffer,
davmail.imap.ImapConnection.MessageWrapper message) |
protected void |
appendEnvelopeHeader(StringBuilder buffer,
String[] value) |
protected void |
appendEnvelopeHeaderValue(StringBuilder buffer,
String value) |
protected void |
appendMailEnvelopeHeader(StringBuilder buffer,
String[] value) |
protected ExchangeSession.Condition |
appendNotSearchParams(String token,
davmail.imap.ImapConnection.SearchConditions conditions) |
protected ExchangeSession.MultiCondition |
appendOrSearchParams(String token,
davmail.imap.ImapConnection.SearchConditions conditions) |
protected ExchangeSession.Condition |
appendSearchParam(davmail.imap.ImapConnection.ImapTokenizer tokens,
String token,
davmail.imap.ImapConnection.SearchConditions conditions) |
protected ExchangeSession.Condition |
buildConditions(davmail.imap.ImapConnection.SearchConditions conditions,
davmail.imap.ImapConnection.ImapTokenizer tokens) |
protected String |
buildFolderContext(String folderToken) |
protected void |
checkInfiniteLoop(String line)
Detect infinite loop on the client side.
|
protected String |
decodeFolderPath(String folderPath) |
protected String |
encodeFolderPath(String folderPath) |
protected boolean |
expunge(boolean silent) |
protected String[] |
getRequestedHeaders(String partIndexString) |
protected List<Long> |
handleSearch(davmail.imap.ImapConnection.ImapTokenizer tokens) |
protected void |
handleStore(String commandId,
ImapConnection.AbstractRangeIterator rangeIterator,
String action,
String flags) |
protected void |
parseCredentials(davmail.imap.ImapConnection.ImapTokenizer tokens)
Decode IMAP credentials
|
void |
run() |
protected void |
sendSubFolders(String command,
String folderPath,
boolean recursive,
boolean wildcard,
boolean specialOnly) |
protected void |
splitUserName()
Detect shared mailbox access.
|
protected void |
updateFlags(ExchangeSession.Message message,
String action,
String flags) |
close, logConnection, readClient, sendClient, sendClient, sendClient, sendClient
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
protected String baseMailboxPath
protected String lastCommand
protected int lastCommandCount
public ImapConnection(Socket clientSocket)
clientSocket
- IMAP client socketprotected void checkInfiniteLoop(String line) throws IOException
line
- IMAP command lineIOException
- on infinite loopprotected void splitUserName()
protected void handleStore(String commandId, ImapConnection.AbstractRangeIterator rangeIterator, String action, String flags) throws IOException
IOException
protected ExchangeSession.Condition buildConditions(davmail.imap.ImapConnection.SearchConditions conditions, davmail.imap.ImapConnection.ImapTokenizer tokens) throws IOException
IOException
protected List<Long> handleSearch(davmail.imap.ImapConnection.ImapTokenizer tokens) throws IOException
IOException
protected void appendEnvelope(StringBuilder buffer, davmail.imap.ImapConnection.MessageWrapper message) throws IOException
IOException
protected void appendEnvelopeHeader(StringBuilder buffer, String[] value) throws UnsupportedEncodingException
UnsupportedEncodingException
protected void appendMailEnvelopeHeader(StringBuilder buffer, String[] value)
protected void appendEnvelopeHeaderValue(StringBuilder buffer, String value) throws UnsupportedEncodingException
UnsupportedEncodingException
protected void appendBodyStructure(StringBuilder buffer, davmail.imap.ImapConnection.MessageWrapper message) throws IOException
IOException
protected void appendBodyStructure(StringBuilder buffer, javax.mail.internet.MimeMultipart multiPart) throws IOException, javax.mail.MessagingException
IOException
javax.mail.MessagingException
protected void appendBodyStructure(StringBuilder buffer, javax.mail.internet.MimePart bodyPart) throws IOException, javax.mail.MessagingException
IOException
javax.mail.MessagingException
protected void appendBodyStructureValue(StringBuilder buffer, String value)
protected void appendBodyStructureValue(StringBuilder buffer, int value)
protected void sendSubFolders(String command, String folderPath, boolean recursive, boolean wildcard, boolean specialOnly) throws IOException
IOException
protected ExchangeSession.MultiCondition appendOrSearchParams(String token, davmail.imap.ImapConnection.SearchConditions conditions) throws IOException
IOException
protected ExchangeSession.Condition appendNotSearchParams(String token, davmail.imap.ImapConnection.SearchConditions conditions) throws IOException
IOException
protected ExchangeSession.Condition appendSearchParam(davmail.imap.ImapConnection.ImapTokenizer tokens, String token, davmail.imap.ImapConnection.SearchConditions conditions) throws IOException
IOException
protected ExchangeSession.Condition appendDateSearchParam(davmail.imap.ImapConnection.ImapTokenizer tokens, String token) throws IOException
IOException
protected boolean expunge(boolean silent) throws IOException
IOException
protected void updateFlags(ExchangeSession.Message message, String action, String flags) throws IOException
IOException
protected void parseCredentials(davmail.imap.ImapConnection.ImapTokenizer tokens) throws IOException
tokens
- tokensIOException
- on errorCopyright © 2001–2024 MickaĆ«l Guessant. All rights reserved.