]> pilppa.org Git - libplp.git/blob - src/Device.cc
api fixes and cleanups
[libplp.git] / src / Device.cc
1 /*
2  * Device.cc
3  *
4  *  Created on: Mar 4, 2011
5  *      Author: lamikr
6  */
7 #include "log.h"
8
9 #include "Device.hh"
10
11 using namespace std;
12 using namespace plp;
13
14 Device::Device(string id_param,
15                 string type_param) {
16         id                      = id_param;
17         type                    = type_param;
18         lifecycle_status        = LIFECYCLE_STATUS__UNAVAILABLE;
19 }
20
21 Device::Device(std::string id_param,
22                 string type_param,
23                 string name_param,
24                 plp::EnumDeviceLifeCycleStatus status_param) {
25         id                      = id_param;
26         type                    = type_param;
27         name                    = name_param;
28         lifecycle_status        = status_param;
29 }
30
31 //Device::~Device() {
32 //      log_debug("Device: constructor\n");
33 //}
34
35 string Device::get_id() {
36         return id;
37 }
38
39 string Device::get_name() {
40         return name;
41 }
42
43 void Device::set_name(string name_param) {
44         name    = name_param;
45 }
46
47 EnumDeviceLifeCycleStatus Device::get_lifecycle_state() {
48         return lifecycle_status;
49 }
50
51 string Device::get_type() {
52         return type;
53 }