blob: 5a5aba3e7cd61793bb9096831f48545d50b48e36 [file] [log] [blame]
Chris Masone8fe2c7e2011-06-09 15:51:19 -07001// Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "shill/property_store_interface.h"
6
7#include <map>
8#include <string>
9#include <vector>
10
11#include <base/basictypes.h>
12#include <base/logging.h>
13
14#include "shill/error.h"
15
16using std::map;
17using std::string;
18using std::vector;
19
20namespace shill {
21
22PropertyStoreInterface::PropertyStoreInterface() {}
23
24PropertyStoreInterface::~PropertyStoreInterface() {}
25
26bool PropertyStoreInterface::SetBoolProperty(const std::string& name,
27 bool value,
28 Error *error) {
29 return ReturnError(name, error);
30}
31
32bool PropertyStoreInterface::SetInt16Property(const std::string& name,
33 int16 value,
34 Error *error) {
35 return ReturnError(name, error);
36}
37
38bool PropertyStoreInterface::SetInt32Property(const std::string& name,
39 int32 value,
40 Error *error) {
41 return ReturnError(name, error);
42}
43
44bool PropertyStoreInterface::SetStringProperty(const std::string& name,
45 const std::string& value,
46 Error *error) {
47 return ReturnError(name, error);
48}
49
50bool PropertyStoreInterface::SetStringmapProperty(
51 const std::string& name,
52 const std::map<std::string, std::string>& values,
53 Error *error) {
54 return ReturnError(name, error);
55}
56
57bool PropertyStoreInterface::SetStringsProperty(
58 const std::string& name,
59 const std::vector<std::string>& values,
60 Error *error) {
61 return ReturnError(name, error);
62}
63
64bool PropertyStoreInterface::SetUint8Property(const std::string& name,
65 uint8 value,
66 Error *error) {
67 return ReturnError(name, error);
68}
69
70bool PropertyStoreInterface::SetUint16Property(const std::string& name,
71 uint16 value,
72 Error *error) {
73 return ReturnError(name, error);
74}
75
76bool PropertyStoreInterface::SetUint32Property(const std::string& name,
77 uint32 value,
78 Error *error) {
79 return ReturnError(name, error);
80}
81
82bool PropertyStoreInterface::ReturnError(const std::string& name,
83 Error *error) {
84 NOTIMPLEMENTED() << name << " is not writable.";
85 if (error)
86 error->Populate(Error::kInvalidArguments, name + " is not writable.");
87 return false;
88}
89
90} // namespace shill