Changed the Map implementations to List since Map implementations are not very well supported by CFX

revert-70aa11f8
Dulitha Wijewantha 10 years ago
parent 0ffa15f463
commit 394d841d4b

@ -18,140 +18,147 @@ package org.wso2.carbon.device.mgt.common;
import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlRootElement;
import java.util.List; import java.util.List;
import java.util.Map;
@XmlRootElement public class Device {
@XmlRootElement
public class Device { private int id;
private String type;
private int id; private String description;
private String type; private String name;
private String description; private Long dateOfEnrolment;
private String name; private Long dateOfLastUpdate;
private Long dateOfEnrolment; private String ownership;
private Long dateOfLastUpdate; private boolean status;
private String ownership; private int deviceTypeId;
private boolean status; private String deviceIdentifier;
private int deviceTypeId; private String owner;
private String deviceIdentifier; private List<Feature> features;
private String owner; private List<Device.Property> properties;
private List<Feature> features;
private Map<String, String> properties; @XmlElement public int getId() {
return id;
@XmlElement }
public int getId() {
return id; public void setId(int id) {
} this.id = id;
}
public void setId(int id) {
this.id = id; @XmlElement public String getDescription() {
} return description;
}
@XmlElement
public String getDescription() { public void setDescription(String description) {
return description; this.description = description;
} }
public void setDescription(String description) { @XmlElement public String getName() {
this.description = description; return name;
} }
@XmlElement public void setName(String name) {
public String getName() { this.name = name;
return name; }
}
@XmlElement public Long getDateOfEnrolment() {
public void setName(String name) { return dateOfEnrolment;
this.name = name; }
}
public void setDateOfEnrolment(Long dateOfEnrolment) {
@XmlElement this.dateOfEnrolment = dateOfEnrolment;
public Long getDateOfEnrolment() { }
return dateOfEnrolment;
} @XmlElement public Long getDateOfLastUpdate() {
return dateOfLastUpdate;
public void setDateOfEnrolment(Long dateOfEnrolment) { }
this.dateOfEnrolment = dateOfEnrolment;
} public void setDateOfLastUpdate(Long dateOfLastUpdate) {
this.dateOfLastUpdate = dateOfLastUpdate;
@XmlElement }
public Long getDateOfLastUpdate() {
return dateOfLastUpdate; @XmlElement public String getOwnership() {
} return ownership;
}
public void setDateOfLastUpdate(Long dateOfLastUpdate) {
this.dateOfLastUpdate = dateOfLastUpdate; public void setOwnership(String ownership) {
} this.ownership = ownership;
}
@XmlElement
public String getOwnership() { @XmlElement public boolean isStatus() {
return ownership; return status;
} }
public void setOwnership(String ownership) { public void setStatus(boolean status) {
this.ownership = ownership; this.status = status;
} }
@XmlElement @XmlElement public int getDeviceTypeId() {
public boolean isStatus() { return deviceTypeId;
return status; }
}
public void setDeviceTypeId(int deviceTypeId) {
public void setStatus(boolean status) { this.deviceTypeId = deviceTypeId;
this.status = status; }
}
@XmlElement public String getDeviceIdentifier() {
@XmlElement return deviceIdentifier;
public int getDeviceTypeId() { }
return deviceTypeId;
} public void setDeviceIdentifier(String deviceIdentifier) {
this.deviceIdentifier = deviceIdentifier;
public void setDeviceTypeId(int deviceTypeId) { }
this.deviceTypeId = deviceTypeId;
} @XmlElement public String getOwner() {
return owner;
@XmlElement }
public String getDeviceIdentifier() {
return deviceIdentifier; public void setOwner(String owner) {
} this.owner = owner;
}
public void setDeviceIdentifier(String deviceIdentifier) {
this.deviceIdentifier = deviceIdentifier; @XmlElement public List<Feature> getFeatures() {
} return features;
}
@XmlElement
public String getOwner() { public void setFeatures(List<Feature> features) {
return owner; this.features = features;
} }
public void setOwner(String owner) { @XmlElement public String getType() {
this.owner = owner; return type;
} }
@XmlElement public void setType(String type) {
public List<Feature> getFeatures() { this.type = type;
return features; }
}
@XmlElement public List<Device.Property> getProperties() {
public void setFeatures(List<Feature> features) { return properties;
this.features = features; }
}
public void setProperties(List<Device.Property> properties) {
@XmlElement this.properties = properties;
public String getType() { }
return type;
} public static class Property {
public void setType(String type) { private String name;
this.type = type; private String value;
}
public String getName() {
@XmlElement return name;
public Map<String, String> getProperties() { }
return properties;
} public void setName(String name) {
this.name = name;
public void setProperties(Map<String, String> properties) { }
this.properties = properties;
} public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
}
} }

Loading…
Cancel
Save