blob: 511c3c214c9de4a4c6b16301ae7349e0fb4e82e3 [file] [log] [blame]
Thieu Le3426c8f2012-01-11 17:35:11 -08001// Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
Paul Stewartf1ce5d22011-05-19 13:10:20 -07002// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef SHILL_ETHERNET_SERVICE_
6#define SHILL_ETHERNET_SERVICE_
7
8#include <base/basictypes.h>
9
Paul Stewart26b327e2011-10-19 11:38:09 -070010#include "shill/event_dispatcher.h"
Chris Masone2b105542011-06-22 10:58:09 -070011#include "shill/refptr_types.h"
Paul Stewartf1ce5d22011-05-19 13:10:20 -070012#include "shill/service.h"
13
14namespace shill {
15
Chris Masone6791a432011-07-12 13:23:19 -070016class ControlInterface;
17class EventDispatcher;
18class Manager;
Thieu Le3426c8f2012-01-11 17:35:11 -080019class Metrics;
Chris Masone6791a432011-07-12 13:23:19 -070020
Paul Stewartf1ce5d22011-05-19 13:10:20 -070021class EthernetService : public Service {
22 public:
23 EthernetService(ControlInterface *control_interface,
24 EventDispatcher *dispatcher,
Thieu Le3426c8f2012-01-11 17:35:11 -080025 Metrics *metrics,
Chris Masone6791a432011-07-12 13:23:19 -070026 Manager *manager,
mukesh agrawal51a7e932011-07-27 16:18:26 -070027 const EthernetRefPtr &device);
Paul Stewartf1ce5d22011-05-19 13:10:20 -070028 ~EthernetService();
Darin Petkov4d6d9412011-08-24 13:19:54 -070029
Chris Masone34af2182011-08-22 11:59:36 -070030 // ethernet_<MAC>
Chris Masone6515aab2011-10-12 16:19:09 -070031 virtual std::string GetStorageIdentifier() const;
Chris Masone34af2182011-08-22 11:59:36 -070032
Paul Stewartf1ce5d22011-05-19 13:10:20 -070033 private:
Chris Masone34af2182011-08-22 11:59:36 -070034 static const char kServiceType[];
35
Gaurav Shah1b7a6162011-11-09 11:41:01 -080036 std::string GetDeviceRpcId(Error *error);
Chris Masone95207da2011-06-29 16:50:49 -070037
Chris Masone2b105542011-06-22 10:58:09 -070038 EthernetRefPtr ethernet_;
Paul Stewartf1ce5d22011-05-19 13:10:20 -070039 DISALLOW_COPY_AND_ASSIGN(EthernetService);
40};
41
42} // namespace shill
43
44#endif // SHILL_ETHERNET_SERVICE_