| Index: sync/test/engine/injectable_sync_core_proxy.cc
|
| diff --git a/sync/test/engine/injectable_sync_core_proxy.cc b/sync/test/engine/injectable_sync_core_proxy.cc
|
| deleted file mode 100644
|
| index 4041736f91911865fbfc3c47864546105bebcfdc..0000000000000000000000000000000000000000
|
| --- a/sync/test/engine/injectable_sync_core_proxy.cc
|
| +++ /dev/null
|
| @@ -1,51 +0,0 @@
|
| -// Copyright 2014 The Chromium Authors. All rights reserved.
|
| -// Use of this source code is governed by a BSD-style license that can be
|
| -// found in the LICENSE file.
|
| -
|
| -#include "sync/test/engine/injectable_sync_core_proxy.h"
|
| -
|
| -#include "sync/engine/non_blocking_type_processor.h"
|
| -#include "sync/engine/non_blocking_type_processor_core_interface.h"
|
| -
|
| -namespace syncer {
|
| -
|
| -InjectableSyncCoreProxy::InjectableSyncCoreProxy(
|
| - NonBlockingTypeProcessorCoreInterface* core)
|
| - : is_core_connected_(false), processor_core_(core) {
|
| -}
|
| -
|
| -InjectableSyncCoreProxy::~InjectableSyncCoreProxy() {
|
| -}
|
| -
|
| -void InjectableSyncCoreProxy::ConnectTypeToCore(
|
| - syncer::ModelType type,
|
| - const DataTypeState& data_type_state,
|
| - base::WeakPtr<syncer::NonBlockingTypeProcessor> type_processor) {
|
| - // This class is allowed to participate in only one connection.
|
| - DCHECK(!is_core_connected_);
|
| - is_core_connected_ = true;
|
| -
|
| - // Hands off ownership of our member to the type_processor, while keeping
|
| - // an unsafe pointer to it. This is why we can only connect once.
|
| - scoped_ptr<NonBlockingTypeProcessorCoreInterface> core(processor_core_);
|
| -
|
| - type_processor->OnConnect(core.Pass());
|
| -}
|
| -
|
| -void InjectableSyncCoreProxy::Disconnect(syncer::ModelType type) {
|
| - // This should delete the core, but we don't own it.
|
| - processor_core_ = NULL;
|
| -}
|
| -
|
| -scoped_ptr<SyncCoreProxy> InjectableSyncCoreProxy::Clone() const {
|
| - // This confuses ownership. We trust that our callers are well-behaved.
|
| - return scoped_ptr<SyncCoreProxy>(
|
| - new InjectableSyncCoreProxy(processor_core_));
|
| -}
|
| -
|
| -NonBlockingTypeProcessorCoreInterface*
|
| -InjectableSyncCoreProxy::GetProcessorCore() {
|
| - return processor_core_;
|
| -}
|
| -
|
| -} // namespace syncer
|
|
|