Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9084)

Unified Diff: components/leveldb/leveldb_service_impl.cc

Issue 1708253004: mojo: Get mojo:leveldb and mojo:filesystem compiled into content. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Probable fix to the build flake. Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/leveldb/leveldb_service_impl.h ('k') | content/browser/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/leveldb/leveldb_service_impl.cc
diff --git a/components/leveldb/leveldb_app.cc b/components/leveldb/leveldb_service_impl.cc
similarity index 64%
copy from components/leveldb/leveldb_app.cc
copy to components/leveldb/leveldb_service_impl.cc
index bd8ac71905cca813b8641930506223676f39b7d4..404019e9992ffa0050dd3a5cae7c81c1c64afa7a 100644
--- a/components/leveldb/leveldb_app.cc
+++ b/components/leveldb/leveldb_service_impl.cc
@@ -2,12 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "components/leveldb/leveldb_app.h"
+#include "components/leveldb/leveldb_service_impl.h"
#include "components/leveldb/env_mojo.h"
#include "components/leveldb/leveldb_database_impl.h"
#include "components/leveldb/util.h"
-#include "mojo/shell/public/cpp/connection.h"
#include "third_party/leveldatabase/env_chromium.h"
#include "third_party/leveldatabase/src/include/leveldb/db.h"
#include "third_party/leveldatabase/src/include/leveldb/env.h"
@@ -16,31 +15,16 @@
namespace leveldb {
-LevelDBApp::LevelDBApp() {}
-
-LevelDBApp::~LevelDBApp() {}
-
-void LevelDBApp::Initialize(mojo::Shell* shell,
- const std::string& url,
- uint32_t id) {
- tracing_.Initialize(shell, url);
- thread_ = new LevelDBFileThread;
+LevelDBServiceImpl::LevelDBServiceImpl()
+ : thread_(new LevelDBFileThread) {
}
-bool LevelDBApp::AcceptConnection(mojo::Connection* connection) {
- connection->AddInterface<LevelDBService>(this);
- return true;
-}
-
-void LevelDBApp::Create(mojo::Connection* connection,
- mojo::InterfaceRequest<LevelDBService> request) {
- bindings_.AddBinding(this, std::move(request));
-}
+LevelDBServiceImpl::~LevelDBServiceImpl() {}
-void LevelDBApp::Open(filesystem::DirectoryPtr directory,
- const mojo::String& dbname,
- mojo::InterfaceRequest<LevelDBDatabase> database,
- const OpenCallback& callback) {
+void LevelDBServiceImpl::Open(filesystem::DirectoryPtr directory,
+ const mojo::String& dbname,
+ mojo::InterfaceRequest<LevelDBDatabase> database,
+ const OpenCallback& callback) {
// This is the place where we open a database.
leveldb::Options options;
options.create_if_missing = true;
« no previous file with comments | « components/leveldb/leveldb_service_impl.h ('k') | content/browser/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698