SchemaVersion001.h (1059B)
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */ 3 /* This Source Code Form is subject to the terms of the Mozilla Public 4 * License, v. 2.0. If a copy of the MPL was not distributed with this 5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 6 7 #ifndef DOM_FS_PARENT_DATAMODEL_SCHEMAVERSION001_H_ 8 #define DOM_FS_PARENT_DATAMODEL_SCHEMAVERSION001_H_ 9 10 #include "ResultConnection.h" 11 #include "mozilla/dom/FileSystemTypes.h" 12 #include "mozilla/dom/quota/ForwardDecls.h" 13 14 namespace mozilla::dom::fs { 15 16 struct SchemaVersion001 { 17 static nsresult CreateTables(ResultConnection& aConn, const Origin& aOrigin); 18 19 static Result<DatabaseVersion, QMResult> InitializeConnection( 20 ResultConnection& aConn, const Origin& aOrigin); 21 22 static constexpr DatabaseVersion sVersion = 1; 23 }; 24 25 nsresult SetEncoding(ResultConnection& aConn); 26 27 Result<bool, QMResult> CheckIfEmpty(ResultConnection& aConn); 28 29 } // namespace mozilla::dom::fs 30 31 #endif // DOM_FS_PARENT_DATAMODEL_SCHEMAVERSION001_H_