#include <TimeTracer.h>
#include <string>
-#include <dpl/log/log.h>
#include <vector>
-
-#undef LOG_TAG
-#define LOG_TAG "TIZEN_DEVICEAPI"
+#include <Logger.h>
using namespace std;
using namespace WrtDeviceApis::CommonsJavaScript;
}
JSValueRef JSBookmarkManager::get(JSContextRef ctx, JSObjectRef object, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception){
- LogDebug("Entered");
+ LoggerD("Entered");
TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
AceSecurityStatus status = BOOKMARK_CHECK_ACCESS(BOOKMARK_FUNCTION_API_READ_FUNCS);
TIZEN_SYNC_ACCESS_HANDLER(status, ctx, exception);
BookmarkSearchDataPtr searchData(new BookmarkSearchData(parentFolder,reculsive));
std::vector<BookmarkDataPtr> bookmarkList = BookmarkManager::getInstance()->get(searchData);
unsigned short bookmarksCount = bookmarkList.size();
- LogDebug("count : " << bookmarksCount);
+ LoggerD("count : " << bookmarksCount);
std::vector<JSValueRef> bookmarksArray;
Converter converter(ctx);
for (int i = 0; i < bookmarksCount; i++) {
JSValueRef bookmark;
- LogDebug("bookmarkList["<<i<<"]:" << (bookmarkList[i]->m_title));
+ LoggerD("bookmarkList["<<i<<"]:" << (bookmarkList[i]->m_title));
if (bookmarkList[i]->m_type == BOOKMARKITEM_TYPE)
bookmark = static_cast<JSValueRef>(JSBookmarkItem::createJSObject(ctx, bookmarkList[i]->m_title, bookmarkList[i]->m_url, bookmarkList[i]->m_id, bookmarkList[i]->m_parentId));
else
}
JSValueRef JSBookmarkManager::add(JSContextRef ctx, JSObjectRef object, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception){
- LogDebug("Entered");
+ LoggerD("Entered");
TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
AceSecurityStatus status = BOOKMARK_CHECK_ACCESS(BOOKMARK_FUNCTION_API_WRITE_FUNCS);
TIZEN_SYNC_ACCESS_HANDLER(status, ctx, exception);
try {
bookmarkobj = validator.toObject(0, JSBookmarkItem::getClassRef());
} catch (const TypeMismatchException& err){
- LogDebug("Bookmark's type is not BookmarkItem");
+ LoggerD("Bookmark's type is not BookmarkItem");
bookmarkobj = validator.toObject(0, JSBookmarkFolder::getClassRef());
}
BookmarkData * bookmark = static_cast<BookmarkData *>(JSObjectGetPrivate(bookmarkobj));
bookmark->m_id = BookmarkManager::getInstance()->add(bookmark->m_type, parentId, bookmark->m_title, bookmark->m_url);
bookmark->m_parentId = parentId;
- LogDebug("bookmark id:" << bookmark->m_id);
- LogDebug("bookmark parent id:" << bookmark->m_parentId);
+ LoggerD("bookmark id:" << bookmark->m_id);
+ LoggerD("bookmark parent id:" << bookmark->m_parentId);
}catch( const BasePlatformException& err){
return JSWebAPIException::throwException(ctx, exception, err);
}
JSValueRef JSBookmarkManager::remove(JSContextRef ctx, JSObjectRef object, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception){
- LogDebug("Entered");
+ LoggerD("Entered");
TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
AceSecurityStatus status = BOOKMARK_CHECK_ACCESS(BOOKMARK_FUNCTION_API_WRITE_FUNCS);
TIZEN_SYNC_ACCESS_HANDLER(status, ctx, exception);
try {
bookmarkobj = validator.toObject(0, JSBookmarkItem::getClassRef(), true);
} catch (const TypeMismatchException& err){
- LogDebug("Bookmark's type is not BookmarkItem");
+ LoggerD("Bookmark's type is not BookmarkItem");
bookmarkobj = validator.toObject(0, JSBookmarkFolder::getClassRef(), true);
}