blob: b8686f43b17a31254d36da5f620abc7fafa6d353 [file] [log] [blame]
// Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef SHILL_NICE_MOCK_CONTROL_
#define SHILL_NICE_MOCK_CONTROL_
#include <base/basictypes.h>
#include "shill/control_interface.h"
namespace shill {
// An implementation of the Shill RPC-channel-interface-factory interface that
// returns nice mocks.
class NiceMockControl : public ControlInterface {
public:
NiceMockControl();
virtual ~NiceMockControl();
// Each of these can be called once. Ownership of the appropriate
// interface pointer is given up upon call.
virtual DeviceAdaptorInterface *CreateDeviceAdaptor(Device *device);
virtual IPConfigAdaptorInterface *CreateIPConfigAdaptor(IPConfig *config);
virtual ManagerAdaptorInterface *CreateManagerAdaptor(Manager *manager);
virtual ProfileAdaptorInterface *CreateProfileAdaptor(Profile *profile);
virtual ServiceAdaptorInterface *CreateServiceAdaptor(Service *service);
private:
DISALLOW_COPY_AND_ASSIGN(NiceMockControl);
};
} // namespace shill
#endif // SHILL_NICE_MOCK_CONTROL_