aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/java/sip/communicator/plugin/addrbook
diff options
context:
space:
mode:
authorhristoterezov <hristo@jitsi.org>2014-04-28 17:00:25 +0300
committerhristoterezov <hristo@jitsi.org>2014-04-28 17:00:25 +0300
commitf264230de7944a28b75a1e0af6cb444f60f39abb (patch)
treec88c4711c6ccb02c7fbf7c3676f5b967ec0b1b48 /src/net/java/sip/communicator/plugin/addrbook
parentd9917f1e79060a1e95c4ef57eb14f454a8d8db0b (diff)
downloadjitsi-f264230de7944a28b75a1e0af6cb444f60f39abb.zip
jitsi-f264230de7944a28b75a1e0af6cb444f60f39abb.tar.gz
jitsi-f264230de7944a28b75a1e0af6cb444f60f39abb.tar.bz2
Fixes issue with Outlook COM server arguments and implements logger level for the native logger.
Diffstat (limited to 'src/net/java/sip/communicator/plugin/addrbook')
-rw-r--r--src/net/java/sip/communicator/plugin/addrbook/msoutlook/MsOutlookAddrBookContactSourceService.java37
1 files changed, 24 insertions, 13 deletions
diff --git a/src/net/java/sip/communicator/plugin/addrbook/msoutlook/MsOutlookAddrBookContactSourceService.java b/src/net/java/sip/communicator/plugin/addrbook/msoutlook/MsOutlookAddrBookContactSourceService.java
index 4da53a0..93db055 100644
--- a/src/net/java/sip/communicator/plugin/addrbook/msoutlook/MsOutlookAddrBookContactSourceService.java
+++ b/src/net/java/sip/communicator/plugin/addrbook/msoutlook/MsOutlookAddrBookContactSourceService.java
@@ -51,6 +51,10 @@ public class MsOutlookAddrBookContactSourceService
private static final long MAPI_INIT_VERSION = 0;
private static final long MAPI_MULTITHREAD_NOTIFICATIONS = 0x00000001;
+
+ private static final int NATIVE_LOGGER_LEVEL_INFO = 0;
+
+ private static final int NATIVE_LOGGER_LEVEL_TRACE = 1;
/**
* The thread used to collect the notifications.
@@ -129,25 +133,31 @@ public class MsOutlookAddrBookContactSourceService
if(!isMAPIInitialized)
{
String logFileName = "";
+ String homeLocation = System.getProperty(
+ "net.java.sip.communicator.SC_LOG_DIR_LOCATION");
+ String dirName = System.getProperty(
+ "net.java.sip.communicator.SC_HOME_DIR_NAME");
+
+ if(homeLocation != null && dirName != null)
+ {
+ logFileName = homeLocation + "\\" + dirName + "\\log\\";
+ }
+
+ int logLevel = NATIVE_LOGGER_LEVEL_INFO;
if(logger.isTraceEnabled())
{
- String homeLocation = System.getProperty(
- "net.java.sip.communicator.SC_LOG_DIR_LOCATION");
- String dirName = System.getProperty(
- "net.java.sip.communicator.SC_HOME_DIR_NAME");
-
- if(homeLocation != null && dirName != null)
- {
- logFileName = homeLocation + "\\" + dirName
- + "\\log\\";
- }
+ logLevel = NATIVE_LOGGER_LEVEL_TRACE;
}
-
+
+ logger.info("Init mapi with log level " + logLevel + " and log file"
+ + " path " + logFileName);
+
MAPIInitialize(
MAPI_INIT_VERSION,
MAPI_MULTITHREAD_NOTIFICATIONS,
notificationDelegate,
- logFileName);
+ logFileName,
+ logLevel);
isMAPIInitialized = true;
}
}
@@ -191,7 +201,8 @@ public class MsOutlookAddrBookContactSourceService
long version,
long flags,
NotificationsDelegate callback,
- String logFileName)
+ String logFileName,
+ int logLevel)
throws MsOutlookMAPIHResultException;
/**