3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://floralicense.org/license/
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
19 /*@file: IntHistory.cpp
20 *@brief: Used to define History
23 #include "IntHistoryData.h"
25 using namespace Tizen::App;
26 using namespace Tizen::Base;
27 using namespace Tizen::Base::Collection;
28 using namespace Tizen::Base::Utility;
29 using namespace Tizen::Content;
30 using namespace Tizen::Graphics;
31 using namespace Tizen::Io;
32 using namespace Tizen::System;
33 using namespace Tizen::Locales;
34 using namespace Tizen::Media;
35 using namespace Tizen::Ui;
36 using namespace Tizen::Ui::Controls;
38 History::History(void)
49 AppLog("History::History(void)");
50 __visitedTime.SetValue(0,0,0);
53 History::History(const History& hs)
55 AppLog("History::History(const History& hs)");
56 __historyId = hs.__historyId;
57 __historyTitle = hs.__historyTitle;
58 __historyUrl = hs.__historyUrl;
61 History::~History(void)
63 if(__pThumbnail != null)
65 delete __pThumbnail; //TODO To get this reviewed
67 AppLog("History::~History()");
71 History::operator =(const History& rhs)
75 __historyId = rhs.__historyId;
76 __historyTitle = rhs.__historyTitle;
77 __historyUrl = rhs.__historyUrl;
83 History::GetHistoryId(void) const
89 History::GetHistoryTitle(void) const
91 return __historyTitle;
95 History::GetHistoryUrl(void) const
101 History::GetVisitedTime(void) const
103 return __visitedTime;
107 History::GetHistoryIconPath(void) const
113 History::GetFaviconId(void) const
119 History::GetBookmarkId(void) const
125 History::GetVisitedCount(void) const
127 return __visitedCount;
131 History::GetThumbnail(void) const
137 History::GetThumbnailPath(void) const
139 return __thumbnailPath;
143 History::SetHistoryId(const String& strHistoryId)
145 __historyId = strHistoryId;
150 History::SetHistoryTitle(String& strHistoryTitle)
152 strHistoryTitle.Trim();
153 __historyTitle = strHistoryTitle;
158 History::SetHistoryUrl(const String& strHistoryUrl)
160 __historyUrl = strHistoryUrl;
165 History::SetVisitedTime(const DateTime& strVisitedTime)
167 __visitedTime = strVisitedTime;
172 History::SetIconPath(const String& strFilePath)
174 __iconPath = strFilePath;
179 History::SetFaviconId(const String& strFaviconId)
181 __faviconId = strFaviconId;
185 History::SetBookmarkId(const String& bookmarkId)
187 __bookmarkId = bookmarkId;
191 History::SetVisitedCount(int& visitedCount)
193 __visitedCount = visitedCount;
197 History::SetThumbnail(Bitmap* thumbnail)
199 //TODO To get this reviewed
200 if(__pThumbnail != thumbnail && __pThumbnail != null) {
203 __pThumbnail = thumbnail;
207 History::SetThumbnailPath(String& thumbnailPath)
209 __thumbnailPath = thumbnailPath;