wrt-plugins-tizen_0.4.23
[framework/web/wrt-plugins-tizen.git] / src / MessagePort / JSLocalMessagePort.cpp
index 6bb3c50..4d438af 100644 (file)
@@ -23,8 +23,6 @@
  */
 
 #include "JSLocalMessagePort.h"
-
-#include <dpl/log/log.h>
 #include <CommonsJavaScript/Validator.h>
 #include <CommonsJavaScript/Converter.h>
 #include <CommonsJavaScript/JSCallbackManager.h>
@@ -36,6 +34,7 @@
 #include "EventLocalMessagePortRemoveMessagePortListener.h"
 #include "MessagePortListenerManager.h"
 #include "MessagePortJSUtil.h"
+#include <Logger.h>
 
 #define TIZEN_LOCAL_MESSAGE_PORT                                "LocalMessagePort"
 
@@ -94,7 +93,7 @@ const JSClassDefinition* JSLocalMessagePort::getClassInfo()
 
 const JSClassRef JSLocalMessagePort::getClassRef()
 {
-       LogInfo("entered");
+       LoggerI("entered");
        if (!m_jsClassRef) {
                m_jsClassRef = JSClassCreate(&m_classInfo);
        }
@@ -158,7 +157,7 @@ JSValueRef JSLocalMessagePort::getMessagePortName(JSContextRef context,
        }
        catch(BasePlatformException &e)
        {
-               LogWarning("trying to get incorrect value");
+               LoggerW("trying to get incorrect value");
        }
 
        return JSValueMakeUndefined(context);
@@ -176,7 +175,7 @@ JSValueRef JSLocalMessagePort::getIsTrusted(JSContextRef context,
        }
        catch(BasePlatformException &e)
        {
-               LogWarning("trying to get incorrect value");
+               LoggerW("trying to get incorrect value");
        }
 
        return JSValueMakeUndefined(context);
@@ -189,7 +188,7 @@ JSValueRef JSLocalMessagePort::addMessagePortListener(JSContextRef context,
                const JSValueRef arguments[],
                JSValueRef* exception)
 {
-       LogDebug("entered");
+       LoggerD("entered");
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        LocalMessagePortPtr localMessagePort;
        JSContextRef gContext;
@@ -206,7 +205,7 @@ JSValueRef JSLocalMessagePort::addMessagePortListener(JSContextRef context,
        }
        catch(BasePlatformException &e)
        {
-               LogError("No private object");
+               LoggerE("No private object");
                return JSWebAPIException::throwException(context, exception, e);
        }
 
@@ -243,7 +242,7 @@ JSValueRef JSLocalMessagePort::addMessagePortListener(JSContextRef context,
        }
        Catch(Exception)
        {
-               LogError("Error on platform : " << _rethrown_exception.GetMessage());
+               LoggerE("Error on platform : " << _rethrown_exception.GetMessage());
                return JSWebAPIException::throwException(context, exception,
                                UnknownException("Plugin's internal error"));
        }
@@ -280,7 +279,7 @@ JSValueRef JSLocalMessagePort::addMessagePortListener(JSContextRef context,
        }
        catch(BasePlatformException &e)
        {
-               LogError("Error on conversion : " << e.getMessage());
+               LoggerE("Error on conversion : " << e.getMessage());
                return JSWebAPIException::throwException(context, exception,
                                UnknownException("Internal error"));
        }
@@ -296,7 +295,7 @@ JSValueRef JSLocalMessagePort::removeMessagePortListener(JSContextRef context,
                const JSValueRef arguments[],
                JSValueRef* exception)
 {
-       LogDebug("entered");
+       LoggerD("entered");
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        LocalMessagePortPtr localMessagePort;
        JSContextRef gContext;
@@ -313,7 +312,7 @@ JSValueRef JSLocalMessagePort::removeMessagePortListener(JSContextRef context,
        }
        catch(BasePlatformException &e)
        {
-               LogError("No private object");
+               LoggerE("No private object");
                return JSWebAPIException::throwException(context, exception, e);
        }
 
@@ -341,7 +340,7 @@ JSValueRef JSLocalMessagePort::removeMessagePortListener(JSContextRef context,
        }
        Catch(Exception)
        {
-               LogError("Error on platform : " << _rethrown_exception.GetMessage());
+               LoggerE("Error on platform : " << _rethrown_exception.GetMessage());
                return JSWebAPIException::throwException(context, exception,
                                UnknownException("Internal error"));
        }