зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1264642 - Part 1. Remove unused methods from IDBObjectStore::StructuredCloneWriteInfo. r=baku
MozReview-Commit-ID: 8MIFD0MizOo
This commit is contained in:
Родитель
4091115d2e
Коммит
e4b3f7ccbb
|
@ -107,36 +107,6 @@ struct IDBObjectStore::StructuredCloneWriteInfo
|
|||
{
|
||||
MOZ_COUNT_DTOR(StructuredCloneWriteInfo);
|
||||
}
|
||||
|
||||
bool
|
||||
operator==(const StructuredCloneWriteInfo& aOther) const
|
||||
{
|
||||
return this->mCloneBuffer.nbytes() == aOther.mCloneBuffer.nbytes() &&
|
||||
this->mCloneBuffer.data() == aOther.mCloneBuffer.data() &&
|
||||
this->mBlobOrMutableFiles == aOther.mBlobOrMutableFiles &&
|
||||
this->mDatabase == aOther.mDatabase &&
|
||||
this->mOffsetToKeyProp == aOther.mOffsetToKeyProp;
|
||||
}
|
||||
|
||||
bool
|
||||
SetFromSerialized(const SerializedStructuredCloneWriteInfo& aOther)
|
||||
{
|
||||
if (aOther.data().IsEmpty()) {
|
||||
mCloneBuffer.clear();
|
||||
} else {
|
||||
auto* aOtherBuffer =
|
||||
reinterpret_cast<uint64_t*>(
|
||||
const_cast<uint8_t*>(aOther.data().Elements()));
|
||||
if (!mCloneBuffer.copy(aOtherBuffer, aOther.data().Length())) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
mBlobOrMutableFiles.Clear();
|
||||
|
||||
mOffsetToKeyProp = aOther.offsetToKeyProp();
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
namespace {
|
||||
|
|
Загрузка…
Ссылка в новой задаче