mirror of
https://github.com/moparisthebest/davmail
synced 2024-12-13 03:02:22 -05:00
EWS: Exchange 2010 message handling
git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@1298 3d1905a2-6b24-0410-a738-b14d5a86fcbd
This commit is contained in:
parent
37d795d027
commit
a1916248d6
@ -241,7 +241,7 @@ public class EwsExchangeSession extends ExchangeSession {
|
||||
message.read = response.getBoolean(Field.get("read").getResponseName());
|
||||
message.junk = response.getBoolean(Field.get("junk").getResponseName());
|
||||
message.flagged = "2".equals(response.get(Field.get("flagStatus").getResponseName()));
|
||||
message.draft = "9".equals(response.get(Field.get("messageFlags").getResponseName())) || "8".equals(response.get(Field.get("messageFlags").getResponseName()));
|
||||
message.draft = (response.getInt(Field.get("messageFlags").getResponseName()) & 8) != 0;
|
||||
String lastVerbExecuted = response.get(Field.get("lastVerbExecuted").getResponseName());
|
||||
message.answered = "102".equals(lastVerbExecuted) || "103".equals(lastVerbExecuted);
|
||||
message.forwarded = "104".equals(lastVerbExecuted);
|
||||
|
@ -78,7 +78,7 @@ public class AbstractDavMailTestCase extends TestCase {
|
||||
protected MimeMessage createMimeMessage() throws MessagingException {
|
||||
MimeMessage mimeMessage = new MimeMessage((Session) null);
|
||||
mimeMessage.addHeader("To", "test@test.local");
|
||||
mimeMessage.setText("Test message");
|
||||
mimeMessage.setText("Test message\n");
|
||||
mimeMessage.setSubject("Test subject");
|
||||
return mimeMessage;
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ public class TestExchangeSessionMessage extends AbstractExchangeSessionTestCase
|
||||
MimeMessage mimeMessage = new MimeMessage(null, new SharedByteArrayInputStream(content));
|
||||
assertTrue(mimeMessage.getHeader("To")[0].indexOf("test@test.local") >= 0);
|
||||
assertEquals("Test subject", mimeMessage.getSubject());
|
||||
assertEquals("Test message", mimeMessage.getContent());
|
||||
assertEquals("Test message\n", mimeMessage.getContent());
|
||||
}
|
||||
|
||||
public void testProcessMessage() throws IOException, MessagingException {
|
||||
|
Loading…
Reference in New Issue
Block a user