1
0
mirror of https://github.com/moparisthebest/davmail synced 2024-11-11 20:05:03 -05:00

Enable Webdav/Galfind failover on Exchange 2007

git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@1446 3d1905a2-6b24-0410-a738-b14d5a86fcbd
This commit is contained in:
mguessan 2010-09-14 20:33:06 +00:00
parent 6d1b4e384a
commit 488b01756c

View File

@ -497,6 +497,15 @@ public class DavExchangeSession extends ExchangeSession {
disableGalLookup = true;
getEmailAndAliasFromOptions();
// failover: try to get email through Webdav and Galfind
if (mailPath == null || email == null) {
try {
buildEmail(method.getURI().getHost());
} catch (URIException uriException) {
LOGGER.warn(uriException);
}
}
// build standard mailbox link with email
mailPath = "/exchange/" + email + '/';
}
@ -1372,7 +1381,7 @@ public class DavExchangeSession extends ExchangeSession {
String exdates = getPropertyIfExists(davPropertySet, "exdate");
if (exdates != null) {
String[] exdatearray = exdates.split(",");
for (String exdate:exdatearray) {
for (String exdate : exdatearray) {
vEvent.addPropertyValue("EXDATE",
StringUtil.convertZuluDateTimeToAllDay(convertDateFromExchange(exdate)));
}
@ -1419,7 +1428,7 @@ public class DavExchangeSession extends ExchangeSession {
vAlarm.setPropertyValue("ACTION", "DISPLAY");
vAlarm.setPropertyValue("DISPLAY", "Reminder");
String reminderdelta = getPropertyIfExists(davPropertySet, "reminderdelta");
VProperty vProperty = new VProperty("TRIGGER", "-PT"+reminderdelta+ 'M');
VProperty vProperty = new VProperty("TRIGGER", "-PT" + reminderdelta + 'M');
vProperty.addParam("VALUE", "DURATION");
vAlarm.addProperty(vProperty);
vEvent.addVObject(vAlarm);