diff options
Diffstat (limited to 'common/storage_common.cpp')
-rw-r--r-- | common/storage_common.cpp | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/common/storage_common.cpp b/common/storage_common.cpp index 057dce4..f96097a 100644 --- a/common/storage_common.cpp +++ b/common/storage_common.cpp | |||
@@ -194,23 +194,6 @@ bool DataStore::isInternalKey(const QByteArray &key) | |||
194 | return key.startsWith(s_internalPrefix); | 194 | return key.startsWith(s_internalPrefix); |
195 | } | 195 | } |
196 | 196 | ||
197 | QByteArray DataStore::assembleKey(const QByteArray &key, qint64 revision) | ||
198 | { | ||
199 | Q_ASSERT(revision <= 9223372036854775807); | ||
200 | Q_ASSERT(key.size() == s_lengthOfUid); | ||
201 | return key + QByteArray::number(revision).rightJustified(19, '0', false); | ||
202 | } | ||
203 | |||
204 | QByteArray DataStore::uidFromKey(const QByteArray &key) | ||
205 | { | ||
206 | return key.mid(0, s_lengthOfUid); | ||
207 | } | ||
208 | |||
209 | qint64 DataStore::revisionFromKey(const QByteArray &key) | ||
210 | { | ||
211 | return key.mid(s_lengthOfUid + 1).toLongLong(); | ||
212 | } | ||
213 | |||
214 | QByteArray DataStore::generateUid() | 197 | QByteArray DataStore::generateUid() |
215 | { | 198 | { |
216 | return createUuid(); | 199 | return createUuid(); |