losty.netatmo.model.Home Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of netatmo-api Show documentation
Show all versions of netatmo-api Show documentation
Small adaption of the original Netatmo Android API that can be used with plain Java (>=v7) instead of Android.
package losty.netatmo.model;
import java.util.ArrayList;
import java.util.List;
public class Home {
private String id;
private String name;
private List modules = new ArrayList<>();
private List rooms = new ArrayList<>();
public Home() {
}
public Home(String id, String name) {
this.id = id;
this.name = name;
}
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public List getModules() {
return modules;
}
public void setModules(List modules) {
this.modules = modules;
}
public void addModule(Module module) {
this.modules.add(module);
}
public List getRooms() {
return rooms;
}
public void setRooms(List rooms) {
this.rooms = rooms;
}
public void addRoom(Room room) {
this.rooms.add(room);
}
@Override
public String toString() {
return "Home{" +
"id='" + id + '\'' +
", name='" + name + '\'' +
'}';
}
}