File indexing completed on 2024-04-28 03:50:19

0001 // SPDX-License-Identifier: LGPL-2.1-or-later
0002 //
0003 // SPDX-FileCopyrightText: 2011 Daniel Marth <danielmarth@gmx.at>
0004 //
0005 
0006 #include "OpenCachingCacheLogEntry.h"
0007 
0008 namespace Marble
0009 {
0010 
0011 OpenCachingCacheLogEntry::OpenCachingCacheLogEntry( const QHash<QString, QVariant>& properties )
0012 {
0013     m_cacheId = properties["cacheid"].toULongLong();
0014     m_userName = properties["userid"].toString();
0015     m_logType = properties["logtype"].toString();
0016     m_text = properties["text"].toString();
0017     m_logDate = properties["date"].toDateTime();
0018     m_createdDate = properties["datecreated"].toDateTime();
0019     m_lastModifiedDate = properties["lastmodified"].toDateTime();
0020 }
0021 
0022 void OpenCachingCacheLogEntry::setCacheId( int cacheId )
0023 {
0024     m_cacheId = cacheId;
0025 }
0026 
0027 int OpenCachingCacheLogEntry::cacheId() const
0028 {
0029     return m_cacheId;
0030 }
0031 
0032 void OpenCachingCacheLogEntry::setUserName( const QString& userName )
0033 {
0034     m_userName = userName;
0035 }
0036 
0037 const QString& OpenCachingCacheLogEntry::userName() const
0038 {
0039     return m_userName;
0040 }
0041 
0042 void OpenCachingCacheLogEntry::setLogType( const QString& logType )
0043 {
0044     m_logType = logType;
0045 }
0046 
0047 const QString& OpenCachingCacheLogEntry::logType() const
0048 {
0049     return m_logType;
0050 }
0051 
0052 void OpenCachingCacheLogEntry::setText( const QString& text )
0053 {
0054     m_text = text;
0055 }
0056 
0057 const QString& OpenCachingCacheLogEntry::text() const
0058 {
0059     return m_text;
0060 }
0061 
0062 void OpenCachingCacheLogEntry::setLogDate( const QDateTime& logDate )
0063 {
0064     m_logDate = logDate;
0065 }
0066 
0067 const QDateTime& OpenCachingCacheLogEntry::logDate() const
0068 {
0069     return m_logDate;
0070 }
0071 
0072 void OpenCachingCacheLogEntry::setCreatedDate( const QDateTime& createdDate )
0073 {
0074     m_createdDate = createdDate;
0075 }
0076 
0077 const QDateTime& OpenCachingCacheLogEntry::createdDate() const
0078 {
0079     return m_createdDate;
0080 }
0081 
0082 void OpenCachingCacheLogEntry::setLastModifiedDate( const QDateTime& lastModifiedDate )
0083 {
0084     m_lastModifiedDate = lastModifiedDate;
0085 }
0086 
0087 const QDateTime& OpenCachingCacheLogEntry::lastModifiedDate() const
0088 {
0089     return m_lastModifiedDate;
0090 }
0091 
0092 }